arphaman (Alex Lorenz)
User

Projects

User does not belong to any projects.

User Details

User Since
Jun 25 2014, 4:17 PM (177 w, 5 d)

Recent Activity

Fri, Nov 17

arphaman committed rL318552: [ObjC][ARC] Honor noescape attribute for -Warc-retain-cycles.
[ObjC][ARC] Honor noescape attribute for -Warc-retain-cycles
Fri, Nov 17, 12:46 PM
arphaman closed D40141: [ObjC][ARC] Honor noescape attribute for -Warc-retain-cycles by committing rL318552: [ObjC][ARC] Honor noescape attribute for -Warc-retain-cycles.
Fri, Nov 17, 12:46 PM

Thu, Nov 16

arphaman created D40141: [ObjC][ARC] Honor noescape attribute for -Warc-retain-cycles.
Thu, Nov 16, 10:44 AM

Wed, Nov 15

arphaman committed rL318367: [DeclPrinter] Extract function PrintConstructorInitializers, NFC.
[DeclPrinter] Extract function PrintConstructorInitializers, NFC
Wed, Nov 15, 5:31 PM
arphaman closed D40066: [DeclPrinter] Extract function PrintConstructorInitializers, NFC by committing rL318367: [DeclPrinter] Extract function PrintConstructorInitializers, NFC.
Wed, Nov 15, 5:31 PM
arphaman committed rL318365: [DeclPrinter] Honor TerseOutput for constructors.
[DeclPrinter] Honor TerseOutput for constructors
Wed, Nov 15, 5:31 PM
arphaman closed D39957: [DeclPrinter] Honor TerseOutput for constructors by committing rL318365: [DeclPrinter] Honor TerseOutput for constructors.
Wed, Nov 15, 5:31 PM
arphaman accepted D40066: [DeclPrinter] Extract function PrintConstructorInitializers, NFC.
Wed, Nov 15, 5:31 PM
arphaman added a comment to D35181: Defer addition of keywords to identifier table when loading AST.

Thanks for the patch!

Wed, Nov 15, 4:56 PM
arphaman added a comment to D39957: [DeclPrinter] Honor TerseOutput for constructors.

FYI, please remember to CC cfe-commits for your future patches.

Wed, Nov 15, 4:41 PM
arphaman added a comment to D39957: [DeclPrinter] Honor TerseOutput for constructors.

Thanks. Sure, I will commit the patches today.

Wed, Nov 15, 9:55 AM
arphaman added a comment to D39730: Enabling constructor code completion.

Sorry, what do you mean by "this works in the body of the class"?

Definition of constructor inside class definition has been working even before:

struct foo {
  foo();
  f<CODE_COMPLETE_HERE>
};

Do you mean that a test shall be added in order to check that it still works?

Wed, Nov 15, 9:49 AM

Tue, Nov 14

arphaman updated the diff for D39913: [ObjC] warn about availability attributes missing from a method's declaration when they're specified for a method's definition .

Remove C++ support for now (it will be in a followup patch along with non-member function support).

Tue, Nov 14, 4:49 PM
arphaman added a comment to D39913: [ObjC] warn about availability attributes missing from a method's declaration when they're specified for a method's definition .

Is it not necessary to print a diagnostic when a non-member function declaration is missing an availability attribute?

void foo1();

__attribute__((availability(macos, introduced=10.1)))
void foo1() {
}
Tue, Nov 14, 4:25 PM
arphaman committed rL318215: [refactor][selection] canonicalize decl ref callee to the call expr.
[refactor][selection] canonicalize decl ref callee to the call expr
Tue, Nov 14, 3:11 PM
arphaman committed rL318205: [refactor][selection] canonicalize member expr callee to the full.
[refactor][selection] canonicalize member expr callee to the full
Tue, Nov 14, 2:08 PM
arphaman accepted D39957: [DeclPrinter] Honor TerseOutput for constructors.

LGTM

Tue, Nov 14, 12:58 PM
arphaman committed rL318169: [refactor][extract] avoid extracting expressions from types in functions.
[refactor][extract] avoid extracting expressions from types in functions
Tue, Nov 14, 11:00 AM

Mon, Nov 13

arphaman committed rL318129: [completion] complete ObjC interface names in an expression.
[completion] complete ObjC interface names in an expression
Mon, Nov 13, 5:48 PM
arphaman updated the diff for D39913: [ObjC] warn about availability attributes missing from a method's declaration when they're specified for a method's definition .
  • formatting
  • simplify checks
  • support c++
Mon, Nov 13, 3:41 PM
arphaman added inline comments to D39913: [ObjC] warn about availability attributes missing from a method's declaration when they're specified for a method's definition .
Mon, Nov 13, 3:40 PM

Fri, Nov 10

arphaman added inline comments to D39706: [refactor][extract] Initial implementation of variable captures.
Fri, Nov 10, 6:06 PM
arphaman updated the diff for D39706: [refactor][extract] Initial implementation of variable captures.

Address review comments

Fri, Nov 10, 6:06 PM
arphaman added a comment to D36790: [ObjC] Messages to 'self' in class methods that return 'instancetype' should use the pointer to the class as the result type of the message.

ping

Fri, Nov 10, 4:22 PM
arphaman accepted D39446: [PGO] Detect more structural changes with the stable hash.
Fri, Nov 10, 4:02 PM
arphaman added a comment to D39446: [PGO] Detect more structural changes with the stable hash.

ok, sgtm

Fri, Nov 10, 4:02 PM
arphaman added a comment to D39446: [PGO] Detect more structural changes with the stable hash.

Generally it LG

Fri, Nov 10, 3:44 PM
arphaman added a reviewer for D39913: [ObjC] warn about availability attributes missing from a method's declaration when they're specified for a method's definition : erik.pilkington.
Fri, Nov 10, 11:33 AM
arphaman created D39913: [ObjC] warn about availability attributes missing from a method's declaration when they're specified for a method's definition .
Fri, Nov 10, 11:31 AM
arphaman added a comment to D39730: Enabling constructor code completion.

Also,

Fri, Nov 10, 10:36 AM
arphaman added a comment to D39730: Enabling constructor code completion.

It doesn't look like this works in the body of the class (at least there's no test for it). For that you might have to inject these kind results by performing another lookup when completing inside the body of the class.

Fri, Nov 10, 10:33 AM

Thu, Nov 9

arphaman added a comment to D39836: [clangd] Drop impossible completions (unavailable or inaccessible).

So I probably should have started from the other end, here :-)

I'd really like to make the completion retrieval and ranking more flexible. In particular

  • incorporating results from other sources (indexes: both in-memory and external services).
  • combining more quality signals like usage count and fuzzy-match-strength in a non-lexicographic-sort way The biggest difficulty in *supporting* unusable functions is maintaining the invariant that all unusable functions are ranked lower than usable ones - all code that deals with ranking has to deal with this special case, e.g. by making score a tuple instead of a single number.
Thu, Nov 9, 12:55 PM
arphaman committed rL317832: [index] tag declarations should use the decl role instead of ref.
[index] tag declarations should use the decl role instead of ref
Thu, Nov 9, 12:51 PM
arphaman added inline comments to D39706: [refactor][extract] Initial implementation of variable captures.
Thu, Nov 9, 10:38 AM
arphaman updated the diff for D39706: [refactor][extract] Initial implementation of variable captures.

Address review comments

Thu, Nov 9, 10:38 AM
arphaman committed rL317816: Add _LIBCPP_INLINE_VISIBILITY to __compressed_pair_elem members.
Add _LIBCPP_INLINE_VISIBILITY to __compressed_pair_elem members
Thu, Nov 9, 9:55 AM
arphaman closed D39751: [libc++] Add _LIBCPP_INLINE_VISIBILITY to __compressed_pair_elem members by committing rL317816: Add _LIBCPP_INLINE_VISIBILITY to __compressed_pair_elem members.
Thu, Nov 9, 9:55 AM
arphaman added a comment to D39836: [clangd] Drop impossible completions (unavailable or inaccessible).

I would prefer to make this behaviour configurable.

Thu, Nov 9, 7:57 AM

Wed, Nov 8

arphaman committed rL317737: Remove redundant copy-pasted comment in test file from r317736.
Remove redundant copy-pasted comment in test file from r317736
Wed, Nov 8, 2:47 PM
arphaman committed rL317736: [ObjC] Fix function signature handling for blocks literals with attributes.
[ObjC] Fix function signature handling for blocks literals with attributes
Wed, Nov 8, 2:44 PM
arphaman committed rL317727: [ObjC] Boxed strings should use the nullability from stringWithUTF8String's….
[ObjC] Boxed strings should use the nullability from stringWithUTF8String's…
Wed, Nov 8, 1:33 PM
arphaman closed D39762: [ObjC] Boxed strings should use the nullability from stringWithUTF8String's return type by committing rL317727: [ObjC] Boxed strings should use the nullability from stringWithUTF8String's….
Wed, Nov 8, 1:33 PM

Tue, Nov 7

arphaman accepted D39332: [clang-refactor] Introduce a new rename rule for qualified symbols.

lgtm

Tue, Nov 7, 2:58 PM
arphaman created D39762: [ObjC] Boxed strings should use the nullability from stringWithUTF8String's return type.
Tue, Nov 7, 2:13 PM
arphaman committed rL317620: [ObjC++] Don't warn about pessimizing move for __block variables.
[ObjC++] Don't warn about pessimizing move for __block variables
Tue, Nov 7, 1:40 PM
arphaman created D39751: [libc++] Add _LIBCPP_INLINE_VISIBILITY to __compressed_pair_elem members.
Tue, Nov 7, 11:08 AM
arphaman committed rL317599: [refactor] rename field references in __builtin_offsetof.
[refactor] rename field references in __builtin_offsetof
Tue, Nov 7, 10:31 AM
arphaman committed rL317596: [index] __builtin_offset's field reference is located at the end location.
[index] __builtin_offset's field reference is located at the end location
Tue, Nov 7, 10:26 AM
arphaman added a comment to D39730: Enabling constructor code completion.

This approach doesn't look right. We don't want to code-complete constructors after the .. Instead we want to complete the constructors/destructors in bodies of classes and in out-of-line declarations after ~, right?

Tue, Nov 7, 9:51 AM
arphaman committed rL317593: [index] index field references in __builtin_offset.
[index] index field references in __builtin_offset
Tue, Nov 7, 9:29 AM

Mon, Nov 6

arphaman committed rL317532: Clarify the error message for unsupported aliases on Darwin.
Clarify the error message for unsupported aliases on Darwin
Mon, Nov 6, 4:32 PM
arphaman added a comment to D38708: [AST] Flag the typo-corrected nodes for better tooling.

ping

Mon, Nov 6, 3:54 PM
arphaman created D39706: [refactor][extract] Initial implementation of variable captures.
Mon, Nov 6, 3:40 PM
arphaman accepted D39675: [clang-refactor] Use ClangTool more explicitly by making refaroing actions AST frontend actions..
Mon, Nov 6, 2:09 PM
arphaman added inline comments to D39332: [clang-refactor] Introduce a new rename rule for qualified symbols.
Mon, Nov 6, 2:06 PM
arphaman added a comment to D39676: [clangd] Add rename support..

Side-comment: will want to let the user know about the fact that global symbols aren't really renamed yet until global rename works?

Mon, Nov 6, 2:03 PM
arphaman added a comment to D39435: Adds a json::Expr type to represent intermediate JSON expressions..

Please CC cfe-commits when submitting clangd patches.

Sigh, I'm really sorry - I do try not to forget this.
Is there a way we can have this happen automatically? It looks like an admin could add a Herald rule, I guess there's a reason this isn't set up.

Mon, Nov 6, 2:01 PM
arphaman added a comment to D39435: Adds a json::Expr type to represent intermediate JSON expressions..

Please CC cfe-commits when submitting clangd patches.

Mon, Nov 6, 10:29 AM

Fri, Nov 3

arphaman committed rL317372: Add -fcxx-exceptions for ExtractionSemicolonPolicy.cpp to appease PS4 bots.
Add -fcxx-exceptions for ExtractionSemicolonPolicy.cpp to appease PS4 bots
Fri, Nov 3, 2:31 PM
arphaman committed rL317344: Move Extract.cpp that wasn't moved in r317343.
Move Extract.cpp that wasn't moved in r317343
Fri, Nov 3, 11:21 AM
arphaman committed rL317343: [refactor][extract] insert semicolons into extracted/inserted code.
[refactor][extract] insert semicolons into extracted/inserted code
Fri, Nov 3, 11:12 AM
arphaman closed D39441: [refactor][extract] insert semicolons into extracted/inserted code when needed by committing rL317343: [refactor][extract] insert semicolons into extracted/inserted code.
Fri, Nov 3, 11:12 AM
arphaman added a comment to D39276: [clangd] Handle clangd.applyFix server-side.

Please remember to CC cfe-commits for such patches.

Fri, Nov 3, 10:39 AM · Restricted Project
arphaman accepted D39419: Fix crash when parsing objective-c++ containing invalid lambda.

lgtm

Fri, Nov 3, 9:52 AM

Thu, Nov 2

arphaman added inline comments to D39419: Fix crash when parsing objective-c++ containing invalid lambda.
Thu, Nov 2, 11:51 PM
arphaman committed rL317231: revert r317228: remove unused function from ObjCRuntime.h, NFC.
revert r317228: remove unused function from ObjCRuntime.h, NFC
Thu, Nov 2, 12:43 PM
arphaman committed rL317228: remove unused function from ObjCRuntime.h, NFC.
remove unused function from ObjCRuntime.h, NFC
Thu, Nov 2, 12:02 PM
arphaman added inline comments to D39332: [clang-refactor] Introduce a new rename rule for qualified symbols.
Thu, Nov 2, 11:21 AM
arphaman updated the diff for D39441: [refactor][extract] insert semicolons into extracted/inserted code when needed.

Address review comments

Thu, Nov 2, 11:19 AM
arphaman committed rL317224: [refactor][selection] canonicalize selected string literal to objc.
[refactor][selection] canonicalize selected string literal to objc
Thu, Nov 2, 11:06 AM

Wed, Nov 1

arphaman accepted D39522: [clang-rename] Use add_clang_tool.

LGTM.

Wed, Nov 1, 5:55 PM

Tue, Oct 31

arphaman committed rL317062: [refactor][extract] code extracted from inline method should be placed.
[refactor][extract] code extracted from inline method should be placed
Tue, Oct 31, 6:13 PM
arphaman committed rL317056: [refactor][extract] prohibit extraction of ObjC property setters.
[refactor][extract] prohibit extraction of ObjC property setters
Tue, Oct 31, 5:21 PM
arphaman committed rL317054: [refactor][selection] code ranges can be selected in objc methods.
[refactor][selection] code ranges can be selected in objc methods
Tue, Oct 31, 5:07 PM
arphaman added inline comments to D39050: Add index-while-building support to Clang.
Tue, Oct 31, 4:07 PM
arphaman added inline comments to D39446: [PGO] Detect more structural changes with the stable hash.
Tue, Oct 31, 9:31 AM

Mon, Oct 30

arphaman created D39441: [refactor][extract] insert semicolons into extracted/inserted code when needed.
Mon, Oct 30, 6:36 PM
arphaman committed rL316971: [refactor] select the entire DeclStmt if one ifs decls is selected.
[refactor] select the entire DeclStmt if one ifs decls is selected
Mon, Oct 30, 6:28 PM
arphaman committed rL316966: Typo correct the condition of 'do-while' before exiting its scope.
Typo correct the condition of 'do-while' before exiting its scope
Mon, Oct 30, 3:55 PM
arphaman added inline comments to D39332: [clang-refactor] Introduce a new rename rule for qualified symbols.
Mon, Oct 30, 11:39 AM

Fri, Oct 27

arphaman added a comment to D39377: Avoid eliding the first operand in the gnu "x ?: y" extension.

Thanks for the patch!

Fri, Oct 27, 4:19 PM
arphaman added a comment to D38320: [clang] Fix serializers for `TypeTemplateParmDecl` + related types.

Thanks for your patch! Could you please post a patch with full context (git diff -U99999)?

Fri, Oct 27, 3:32 PM
arphaman updated subscribers of D39057: [clangd][WIP] Integrate the refactoring actions into clangd.
Fri, Oct 27, 2:06 PM · Restricted Project
arphaman added a dependency for D39057: [clangd][WIP] Integrate the refactoring actions into clangd: D39276: [clangd] Handle clangd.applyFix server-side.
Fri, Oct 27, 2:02 PM · Restricted Project
arphaman added a dependent revision for D39276: [clangd] Handle clangd.applyFix server-side: D39057: [clangd][WIP] Integrate the refactoring actions into clangd.
Fri, Oct 27, 2:02 PM · Restricted Project
arphaman added a comment to D39057: [clangd][WIP] Integrate the refactoring actions into clangd.

There's another patch (D39276) that tries to add workspace/executeCommand for a slightly different use-case.
Could we take the code for parsing/handling workspace/executeCommand from this patch and extract it into a separate change so that these two patches can be reviewed independently?

@arphaman unless you're far down this path already, I'd actually prefer we land that patch soon and merge this one into it:

  • It's got a pretty narrow scope (1 command, not much logic), and will be ready soon. It's almost actually the isolated patch that @ilya-biryukov describes. This patch is both more general in scope and is stacked on top of other nontrivial changes, so will probably take longer.
  • It makes a couple of different decisions that I think would aid the design here, will leave detailed comments.

    But if people prefer, we can certainly tackle command parsing separately.
Fri, Oct 27, 2:02 PM · Restricted Project
arphaman added inline comments to D39332: [clang-refactor] Introduce a new rename rule for qualified symbols.
Fri, Oct 27, 1:57 PM
arphaman committed rL316780: [refactor] Describe refactorings in the operation classes.
[refactor] Describe refactorings in the operation classes
Fri, Oct 27, 11:19 AM
arphaman closed D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions by committing rL316780: [refactor] Describe refactorings in the operation classes.
Fri, Oct 27, 11:19 AM
arphaman committed rL316778: [Sema] Fix an assert-on-invalid by avoiding function template specialisation.
[Sema] Fix an assert-on-invalid by avoiding function template specialisation
Fri, Oct 27, 11:14 AM
arphaman closed D37341: [Sema] Fix an assert-on-invalid by avoiding function template specialisation deduction for invalid functions with fabricated template arguments by committing rL316778: [Sema] Fix an assert-on-invalid by avoiding function template specialisation.
Fri, Oct 27, 11:14 AM
arphaman added a comment to D39332: [clang-refactor] Introduce a new rename rule for qualified symbols.

I've committed https://reviews.llvm.org/D38985, so you'd have to rebase unfortunately. Things are still somewhat unstable :)

Fri, Oct 27, 10:56 AM
arphaman added inline comments to D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions.
Fri, Oct 27, 9:49 AM

Thu, Oct 26

arphaman updated the diff for D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions.
  • Use a RefactoringDescriptor struct that's accessible from a static function in an operation class.
  • Make createSourceReplacements private.
Thu, Oct 26, 11:50 AM
arphaman added inline comments to D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions.
Thu, Oct 26, 11:48 AM

Wed, Oct 25

arphaman committed rL316631: Allow StmtPrinter to supress implicit 'this' and 'self' base expressions.
Allow StmtPrinter to supress implicit 'this' and 'self' base expressions
Wed, Oct 25, 5:57 PM
arphaman added a comment to D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions.

The updated patch introduces some redundancy between the RefactoringAction and the descriptor interface. I will address this in a follow-up patch.

Wed, Oct 25, 4:13 PM
arphaman updated the diff for D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions.

Remove unused function

Wed, Oct 25, 4:11 PM
arphaman updated the diff for D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions.
  • Refactoring operations like ExtractFunction should be declared in headers and should contain the initiation checks.
  • Refactoring actions can now be all created in one "engine" file.
  • A new descriptor interface describes a rule (name, description + optional editor title).
Wed, Oct 25, 4:09 PM
arphaman added a comment to D38985: [refactor] Add support for editor commands that connect IDEs/editors to the refactoring actions.

Thanks, this looks a bunch simpler.

I have a question about the direction here: AFAICS there's various efforts in the refactoring infrastructure to allow consumers of the Refactor libs (e.g. clang-refactor, clangd, XCode?) to operate without knowing the details of the refactorings.

One example is the treating the identifying Name of a rule as data, instead of referring to a subclass directly. Another is the way options are communicated via OptionsVisitor and Requirements etc, where they could be more directly expressed as members of a Rule-specific struct or parameters to a function.

An interface that truly decouples N refactorings from M consumers has scalability advantages, but there are some things that cut against it:

  • It tends to add complexity/indirection, which can slow down contributors, mask bugs, and makes certain features (ones that don't fit into the existing framework) hard to add.
  • If the generic interfaces aren't enough we pierce them, resulting in both coupling *and* complexity. e.g. Clangd really needs control over how refactorings are exposed: which ones are visible under what names, how the JSON-RPC messages are structured. (Because its protocol isn't really an implementation detail under our control, we need to be able to adapt to/influence editors and evolution of the LSP standard).
Wed, Oct 25, 4:08 PM