Commit Graph

251 Commits

Author SHA1 Message Date
Dmitry Jemerov 2e9a3e6d12 Option to use continuation indent in expression bodies (KT-9818) 2017-06-14 14:37:22 +02:00
Dmitry Jemerov f4c75e61ad Option to use continuation indent in parameter lists 2017-06-14 14:33:52 +02:00
Dmitry Jemerov fc2a1fce8b Remove line break between ) and : if there's a line break before ) 2017-06-14 14:33:42 +02:00
Dmitry Jemerov a0b5a3a8a2 Implement parenthesis wrapping options 2017-06-14 14:33:41 +02:00
Dmitry Jemerov f32dc9e84e Put lambda parameters on the same line as opening curly brace 2017-06-14 14:18:58 +02:00
Andrius Semionovas 8c6f93b899 Add tests for KEEP_LINE_BREAKS 2017-06-14 11:28:57 +02:00
Andrius Semionovas 839141e4f6 Stop formatting line breaks between keywords and parentheses 2017-06-14 11:28:57 +02:00
Andrius Semionovas c6acc4c5be KT-16558 Add space before parentheses config 2017-06-14 11:28:57 +02:00
Ilya Zorin 862631b2ec Handle spaces around dot in type references and before type argument list 2017-06-07 19:43:14 +02:00
Andrius Semionovas 4acb95acb5 Fix KT-16725; Remove spaces between array indices 2017-06-07 19:39:55 +02:00
Nikolay Krasko 6a4590839c Don't merge two lines in formatter after line comment (KT-16032)
#KT-16032 Fixed
2017-02-22 20:12:19 +03:00
Nikolay Krasko d58707972d Keep empty bodies for declarations with comments (KT-16078)
#KT-16078 Fixed
2017-02-17 15:57:11 +03:00
Ilya Zorin c5677f0428 Format spaces around :: 2017-01-09 12:19:29 +01:00
Ilya Zorin ffe80dd549 Format spaces around by keyword (#1016) 2017-01-09 11:19:44 +01:00
Nikolay Krasko 2bb48fc802 Allow empty single-line bodies in property accessors 2016-12-14 13:40:44 +03:00
Nikolay Krasko 2841931ffa Do not force new line in body for empty functions and function expressions (KT-10828)
#KT-10828 Fixed
2016-12-14 13:35:31 +03:00
Nikolay Krasko 43948a0170 Wrap options for constructor parameters
#KT-12176 In Progress
2016-12-08 15:15:12 +03:00
Dmitry Neverov 3cc3ad2b9e Fix spaces in labeled expression (KT-14131)
https://github.com/JetBrains/kotlin/pull/978

(cherry picked from commit fdd5ba7)
2016-10-20 19:22:00 +03:00
Dmitry Neverov c3c5805a5f Fix indent in constructor delegate call (KT-7718)
(cherry picked from commit 5699b14)

 #KT-7718 Fixed
2016-10-18 14:01:51 +03:00
Nikolay Krasko 6a72cebe88 Add indent before colon of super types list on new line (KT-13981, KT-5117)
#KT-13981 Fixed
 #KT-5117 Fixed

(cherry picked from commit dfea3af)
2016-10-17 15:16:48 +03:00
Kirill Rakhman 926deebff5 Format spaces around !is and !in (KT-13314)
#KT-13314 Fixed
2016-08-15 16:21:01 +03:00
Kirill Rakhman 0320bd8184 Formatter: Remove spaces before question mark in nullable types (KT-12830)
#KT-12830 Fixed
2016-06-29 16:15:59 +03:00
Nikolay Krasko f8196d8331 Add space after a semicolon only if there's another child at the same line 2016-06-21 21:54:50 +03:00
Kirill Rakhman b560aab06d Format spaces before enum arguments
Fixes #KT-12714
2016-06-21 21:54:50 +03:00
Kirill Rakhman a520be5509 Format spaces around semicolon
Fixes #KT-12689
2016-06-21 21:54:50 +03:00
Kirill Rakhman db387bd573 Format spaces after annotation in annotated expression
Fixes #KT-12781
2016-06-21 21:54:50 +03:00
Kirill Rakhman ae83330679 Format spaces inside curly braces in string template
Fixes #KT-12791
2016-06-21 21:54:50 +03:00
Kirill Rakhman 655fc45a87 Format spaces around in keyword
Fixes: KT-10680
2016-06-21 21:54:50 +03:00
Kirill Rakhman 5c68681f96 Formatter: handle spaces before value arguments list (KT-12634)
#KT-12634 Fixed
2016-06-07 19:11:28 +03:00
Kirill Rakhman c24960f8d9 Formatter: handle spaces between class name and type parameters (#875)
Fixes #KT-12446
2016-06-01 21:20:56 +03:00
Kirill Rakhman 93ebb3da65 Formatter: handle spaces around 'is' keyword (#874)
Fixes #KT-12548
2016-05-30 20:35:33 +03:00
Nikolay Krasko b107bc401c Formatter: Don't enforce empty line between secondary constructors without body (KT-12175)
#KT-12175 Fixed
2016-05-12 17:26:54 +03:00
Kirill 6e08f06bfd Format spaces in infix call (KT-12018)
#KT-12018 Fixed
2016-04-26 15:21:33 +03:00
Kirill 01b754b318 Format spaces in cast expression (KT-12035)
#KT-12035 Fixed
2016-04-26 15:21:33 +03:00
Nikolay Krasko f2a17bc4c2 Formatter doesn't handle space before angle bracket in method definition (KT-11961)
#KT-11961 Fixed
2016-04-19 21:28:00 +03:00
Kirill Rakhman 146dca2cd6 Formatter: Remove spaces between expression and parentheses
#KT-11476 Fixed
2016-03-21 17:56:04 +03:00
Nikolay Krasko ee50aec734 Don't add a blank line between one line class and object (KT-10965) 2016-03-16 18:41:28 +03:00
Nikolay Krasko 94e8ba7c4b "Code formatter doesn't remove spaces in single line properties" fixed (KT-11076)
#KT-11076 Fixed
2016-03-16 12:38:26 +03:00
Nikolay Krasko 6193987d0d Reformat code should not align comments (KT-4175)
#KT-4175 In Progress
2016-03-16 12:38:17 +03:00
Alexey Sedunov 5dcf531048 Formatter: Leave single space between val/var and value parameter 2015-12-25 18:50:52 +03:00
Nikolay Krasko 8a95f23a23 Adjust formatting for FILE_ANNOTATION_LIST 2015-12-09 16:01:56 +03:00
Alexey Sedunov 40f2a983cc Formatter: Spacing before after semicolon in enum classes 2015-10-24 19:50:51 +03:00
Valentin Kipyatkov 090ea37a32 Fixed test data to use only annotation syntax with @ 2015-10-15 19:20:08 +03:00
Dmitry Jemerov 1523d5bcbf removing static type assertions work in progress 2015-10-12 11:11:23 +02:00
Dmitry Jemerov 4b92bd100c add space between property type parameter list and property name 2015-10-06 16:20:48 +02:00
Denis Zharkov 73799e2c3c Replace deprecated lambda syntax in testData
It's done with similar constructions where possible trying to preserve
intended behavior.
Some usages are removed because they test exactly the feature that
we are going to drop soon.
2015-09-25 08:29:25 +03:00
Natalia Ukhorskaya ba48a5b7fc Formatter: space between type argument list and function literal argument 2015-08-24 12:37:33 +03:00
Mikhail Glukhikh 3f14e74b08 Drop old enum syntax. Comma / semicolon are now a syntactic part of enum entry.
Comma must present now between enum entries, semicolon between last entry & first member, constructor calls must be without colons / specifiers.
A swarm of tests fixed accordingly.
2015-08-11 10:38:10 +03:00
Mikhail Glukhikh 022e7d1169 Deprecated enum syntax removed: most idea tests 2015-08-10 16:24:16 +03:00
Alexey Sedunov d23da408a8 Formatter: Add blank line before class/object declaration inside of declaration body 2015-07-28 18:48:23 +03:00