Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-23 Thread Martin Probst via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL273603: clang-format: [JS] recognize more type locations. (authored by mprobst). Changed prior to commit: http://reviews.llvm.org/D21597?vs=61706=61711#toc Repository: rL LLVM

Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-23 Thread Martin Probst via cfe-commits
mprobst updated this revision to Diff 61706. mprobst marked an inline comment as done. mprobst added a comment. - progress http://reviews.llvm.org/D21597 Files: lib/Format/FormatToken.h lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestJS.cpp Index:

Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-23 Thread Martin Probst via cfe-commits
mprobst marked 2 inline comments as done. Comment at: lib/Format/TokenAnnotator.cpp:155 @@ +154,3 @@ +} else if (Style.Language == FormatStyle::LK_JavaScript && Left->Previous && + Left->Previous->is(TT_JsTypeColon)) { + // let x: (SomeType);

Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-23 Thread Daniel Jasper via cfe-commits
djasper accepted this revision. djasper added a comment. This revision is now accepted and ready to land. Basically looks good. Comment at: lib/Format/TokenAnnotator.cpp:155 @@ +154,3 @@ +} else if (Style.Language == FormatStyle::LK_JavaScript && Left->Previous && +

Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-22 Thread Martin Probst via cfe-commits
mprobst added inline comments. Comment at: lib/Format/TokenAnnotator.cpp:480 @@ -471,1 +479,3 @@ + void parseJSTypeDefinition() { +// `type Name = Type Expression;` djasper wrote: > Why is this necessary? It is not, actually. I was chasing a wrong path

Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-22 Thread Martin Probst via cfe-commits
mprobst updated this revision to Diff 61548. mprobst added a comment. - Remove parseJSTypeDefinition http://reviews.llvm.org/D21597 Files: lib/Format/FormatToken.h lib/Format/TokenAnnotator.cpp unittests/Format/FormatTestJS.cpp Index: unittests/Format/FormatTestJS.cpp

Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-22 Thread Daniel Jasper via cfe-commits
djasper added inline comments. Comment at: lib/Format/TokenAnnotator.cpp:480 @@ -471,1 +479,3 @@ + void parseJSTypeDefinition() { +// `type Name = Type Expression;` Why is this necessary? http://reviews.llvm.org/D21597

Re: [PATCH] D21597: clang-format: [JS] recognize more type locations.

2016-06-22 Thread Martin Probst via cfe-commits
mprobst added a comment. This seems to be getting a bit tricky with the declaration contexts. If you have a better suggestion, please come forward. http://reviews.llvm.org/D21597 ___ cfe-commits mailing list cfe-commits@lists.llvm.org