rsmith (Richard Smith)
User

Projects

User does not belong to any projects.

User Details

User Since
Jul 12 2012, 2:19 PM (253 w, 5 d)

Recent Activity

Yesterday

rsmith accepted D32828: [Modules] Fix conservative assertion for import diagnostics.
Tue, May 23, 4:03 PM
rsmith committed rL303699: [modules] When reparenting a local declaration, don't mark the declaration as.
[modules] When reparenting a local declaration, don't mark the declaration as
Tue, May 23, 3:03 PM
rsmith added a comment to D29951: Load lazily the template specialization in multi-module setups..

In order to create a reasonable test I need to use -error-on-deserialized-decl and I hit a bug: https://bugs.llvm.org/show_bug.cgi?id=32988

Richard, could you help me out with the test? Maybe we could trigger this avoiding the abovementioned bug...

Tue, May 23, 1:18 PM
rsmith accepted D33424: Lexer: allow imaginary constants in GNU mode (only)..

I like it, and it seems like it would nicely generalize if there are more cases that we find need this treatment.

Tue, May 23, 1:04 PM
rsmith added inline comments to D33366: Fix that global delete operator get's assigned to a submodule..
Tue, May 23, 12:46 PM
rsmith added inline comments to D29951: Load lazily the template specialization in multi-module setups..
Tue, May 23, 12:07 PM

Mon, May 22

rsmith added a comment to D33424: Lexer: allow imaginary constants in GNU mode (only)..

Counterproposal: in -std=*++14 onwards, treat this construct as a user-defined literal, but fall back on the built-in interpretation if name lookup doesn't find an operator""i function. (The two interpretations only conflict if the source code explicitly does something like using namespace std::complex_literals;, which seems like a pretty big clue that the user expected 1.0ito be std::complex<double> rather than _Complex double.)

Mon, May 22, 5:17 PM
rsmith committed rL303589: Add option to include multiple lines in snippets..
Add option to include multiple lines in snippets.
Mon, May 22, 4:51 PM
rsmith accepted D31692: [coroutines] Wrap the body of the coroutine in try-catch.

LGTM

Mon, May 22, 3:08 PM
rsmith added inline comments to D33398: Mangle __unaligned in Itanium ABI.
Mon, May 22, 3:05 PM
rsmith added a comment to D30170: Function definition may have uninstantiated body.

Do we really need two different notions of "definition" and "odr definition" here? What goes wrong if we always treat the "instantiation of a friend function definition" case as being a definition?

Mon, May 22, 1:27 PM
rsmith accepted D31627: [coroutines] Skip over passthrough operator co_await.

Does it still make sense for us to have a UO_Coawait at all? As I recall, the only purpose it ever had was to represent a dependent co_await expression that couldn't yet be resolved to a CoawaitExpr. But now we have (and need!) a separate DependentCoawaitExpr node to store unqualified lookup results, it seems that the UnaryOperator portion of the representation serves no purpose (and as seen in this patch, it's getting in the way). Can we remove it?

Mon, May 22, 12:56 PM
rsmith accepted D31608: [coroutines] Add emission of initial and final suspends.

LGTM

Mon, May 22, 12:07 PM
rsmith added inline comments to D31692: [coroutines] Wrap the body of the coroutine in try-catch.
Mon, May 22, 12:00 PM
rsmith added inline comments to D31670: [coroutines] Implement correct GRO lifetime.
Mon, May 22, 11:45 AM
rsmith accepted D31646: [coroutines] Build GRO declaration and return GRO statement.

LGTM

Mon, May 22, 11:15 AM

Fri, May 19

rsmith committed rL303479: Rename RAII objects for performing eager instantiation to have names that.
Rename RAII objects for performing eager instantiation to have names that
Fri, May 19, 6:50 PM
rsmith committed rL303469: Remove last (unnecessary) use of mapping from SourceLocation to Module and.
Remove last (unnecessary) use of mapping from SourceLocation to Module and
Fri, May 19, 5:02 PM
rsmith accepted D33339: Fix valid-for-expr ellipses eaten as invalid decl.

LGTM, thanks!

Fri, May 19, 5:00 PM
rsmith committed rL303468: [modules] Simplify module macro handling in non-local-submodule-visibility mode..
[modules] Simplify module macro handling in non-local-submodule-visibility mode.
Fri, May 19, 4:46 PM
rsmith added a comment to D33366: Fix that global delete operator get's assigned to a submodule..

This is supposed to be handled by Sema::DeclareGlobalAllocationFunction:

Fri, May 19, 3:39 PM
rsmith committed rL303451: Do not issue -Wnullability-completeness for dependent types that are not….
Do not issue -Wnullability-completeness for dependent types that are not…
Fri, May 19, 1:33 PM
rsmith added a comment to D33339: Fix valid-for-expr ellipses eaten as invalid decl.

The check-all target passes even if the ellipsis-after-declarator-id disambiguation as a declarator is removed entirely.

[...]

So, on the whole, the stray ellipsis treatment is both too complicated and not complicated enough.

Fri, May 19, 1:00 PM
rsmith added inline comments to D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC.
Fri, May 19, 11:48 AM

Thu, May 18

rsmith committed rL303398: When a type-id is unexpectedly given a name, assume that the name is unrelated.
When a type-id is unexpectedly given a name, assume that the name is unrelated
Thu, May 18, 7:08 PM
rsmith added a comment to D33339: Fix valid-for-expr ellipses eaten as invalid decl.

Should I assume our "misplaced ellipsis" diagnostic requires that we disambiguate the ill-formed ellipsis-after-declarator-id as a declaration in some cases? If so, do we have tests for that somewhere?

Thu, May 18, 6:51 PM
rsmith accepted D15994: Allow for unfinished #if blocks in preambles..

Some comments, but I'm happy for you to go ahead and commit after addressing them. Thanks!

Thu, May 18, 4:22 PM
rsmith committed rL303373: When we enter a module within a linkage specification, switch the linkage.
When we enter a module within a linkage specification, switch the linkage
Thu, May 18, 12:48 PM
rsmith committed rL303372: Fix the location of "missing ';'" suggestions after annotation tokens..
Fix the location of "missing ';'" suggestions after annotation tokens.
Thu, May 18, 12:35 PM

Wed, May 17

rsmith committed rL303322: [modules] Switch from inferring owning modules based on source location to.
[modules] Switch from inferring owning modules based on source location to
Wed, May 17, 7:42 PM
rsmith accepted D33207: Fix an assertion failure in FormatASTNodeDiagnosticArgument..

LGTM, thanks!

Wed, May 17, 5:44 PM
rsmith accepted D31839: make -Winteger-overflow find overflows in function arguments.
Wed, May 17, 5:07 PM

Tue, May 16

rsmith committed rL303224: [modules] When creating a declaration, cache its owning module immediately.
[modules] When creating a declaration, cache its owning module immediately
Tue, May 16, 5:37 PM
rsmith added inline comments to D31588: Fix PR25627: Certain constant local variables must be usable as template arguments (without being odr-used).
Tue, May 16, 1:57 PM

Mon, May 15

rsmith added inline comments to D33207: Fix an assertion failure in FormatASTNodeDiagnosticArgument..
Mon, May 15, 1:02 PM

Fri, May 12

rsmith committed rL302969: Add LangOptions method to query whether we are tracking the owning module for a….
Add LangOptions method to query whether we are tracking the owning module for a…
Fri, May 12, 5:13 PM
rsmith committed rL302966: Remove unused tracking of owning module for MacroInfo objects..
Remove unused tracking of owning module for MacroInfo objects.
Fri, May 12, 4:54 PM
rsmith committed rL302965: [modules] When creating a declaration, cache its owning module immediately.
[modules] When creating a declaration, cache its owning module immediately
Fri, May 12, 4:40 PM
rsmith committed rL302947: Revert r302932, as it appears to be breaking stage2 for some of our modules….
Revert r302932, as it appears to be breaking stage2 for some of our modules…
Fri, May 12, 1:56 PM
rsmith committed rL302932: [modules] Simplify module macro handling in non-local-submodule-visibility mode..
[modules] Simplify module macro handling in non-local-submodule-visibility mode.
Fri, May 12, 12:09 PM

Thu, May 11

rsmith added a comment to D32178: Delete unstable integration tests.

Clang's regression test suite is not a sensible home for these tests. We should have a home and a plan for system-specific integration tests, but this is not it. Perhaps this should instead be a part of LNT / the test-suite project?

Thu, May 11, 5:04 PM
rsmith committed rL302842: Remove unnecessary mapping from SourceLocation to Module..
Remove unnecessary mapping from SourceLocation to Module.
Thu, May 11, 4:24 PM
rsmith committed rL302825: XFAIL this test for Hexagon..
XFAIL this test for Hexagon.
Thu, May 11, 2:31 PM
rsmith committed rL302818: Work around different -std= default for PS4 target..
Work around different -std= default for PS4 target.
Thu, May 11, 12:31 PM
rsmith committed rL302817: PR22877: When constructing an array via a constructor with a default argument.
PR22877: When constructing an array via a constructor with a default argument
Thu, May 11, 12:11 PM

Wed, May 10

rsmith added a comment to D32332: Add support for transparent overloadable functions in clang.

I'd like to suggest an alternative design: don't add a new attribute., and instead change the semantics of __attribute__((overloadable)) to permit at most one non-overloadable function in an overload set. That one function would implicitly get the transparently_overloadable semantics: it can be overloaded by overloadable functions and doesn't get a mangled name. This is basically exactly how extern "C" and extern "C++" functions overload in C++: you can have up to one extern "C" function plus as many (overloadable) C++ functions as you like.

Wed, May 10, 5:49 PM
rsmith committed rL302750: PR22877: When constructing an array via a constructor with a default argument.
PR22877: When constructing an array via a constructor with a default argument
Wed, May 10, 5:30 PM
rsmith committed rL302737: Changes missed from r302732..
Changes missed from r302732.
Wed, May 10, 3:00 PM
rsmith committed rL302732: Improve diagnosis of unknown template name..
Improve diagnosis of unknown template name.
Wed, May 10, 2:45 PM
rsmith accepted D33013: Driver must return non-zero code on errors in command line.

LGTM

Wed, May 10, 2:29 PM

Tue, May 9

rsmith committed rL302615: When we see a '<' operator, check whether it's a probable typo for a template….
When we see a '<' operator, check whether it's a probable typo for a template…
Tue, May 9, 7:43 PM
rsmith committed rL302603: When instantiating a friend function template, don't forget to inherit default….
When instantiating a friend function template, don't forget to inherit default…
Tue, May 9, 5:14 PM
rsmith committed rL302596: Don't mark a member as a member specialization until we know we're keeping the….
Don't mark a member as a member specialization until we know we're keeping the…
Tue, May 9, 4:15 PM
rsmith added a comment to D16171: Warning on redeclaring with a conflicting asm label.

Er, please ignore the inline review comments; those predated the realisation that this doesn't actually fix the glibc build problem.

Tue, May 9, 3:06 PM
rsmith requested changes to D16171: Warning on redeclaring with a conflicting asm label.
../include/sys/stat.h:16:15: error: cannot apply asm label to function after its first use
hidden_proto (__fxstat)
~~~~~~~~~~~~~~^~~~~~~~~
./../include/libc-symbols.h:420:19: note: expanded from macro 'hidden_proto'
  __hidden_proto (name, , __GI_##name, ##attrs)
  ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./../include/libc-symbols.h:424:33: note: expanded from macro '__hidden_proto'
  extern thread __typeof (name) name __asm__ (__hidden_asmname (#internal)) \
Tue, May 9, 3:06 PM
rsmith added a comment to D33013: Driver must return non-zero code on errors in command line.

Thank you, some of these test typos are ... alarming. =)

Tue, May 9, 2:44 PM
rsmith accepted D32984: [Sema] Implement Core 2094: Trivial copy/move constructor for class with volatile member.

Please first check in a change that just regenerates cxx_dr_status without your changes, to separate out the changes due to the new issues list from the changes due to this patch. (You can go ahead and do that with no review.)

Tue, May 9, 1:00 PM
rsmith added inline comments to D31778: [Modules] Implement ODR-like semantics for tag types in C/ObjC.
Tue, May 9, 12:19 PM
rsmith added inline comments to D32828: [Modules] Fix conservative assertion for import diagnostics.
Tue, May 9, 12:06 PM
rsmith added inline comments to D29951: Load lazily the template specialization in multi-module setups..
Tue, May 9, 12:03 PM
rsmith accepted D31269: [Modules] Allow modules specified by -fmodule-map-file to shadow implicitly found ones.

This makes a lot of sense to me. See also r302463: I think we probably want three levels of shadowing here: the main input shadows -fmodule-map-file, which shadows module maps loaded implicitly. (There's also a question of what we do with module map information loaded from an AST file: currently when that happens, we ignore the tokens for the parsed module map entirely. It might make more sense to have the module loaded from the AST file shadow the module from the module map, especially for an explicit module build, now that we have that functionality.)

Tue, May 9, 10:32 AM
rsmith accepted D32499: Further delay calling DeclMustBeEmitted until it's safe..

Let's go ahead with this. I've been unable to find a testcase that triggers the problem, but we shouldn't keep a known latent bug around just because we don't know how to expose it yet.

Tue, May 9, 10:16 AM

Mon, May 8

rsmith added inline comments to D32984: [Sema] Implement Core 2094: Trivial copy/move constructor for class with volatile member.
Mon, May 8, 4:22 PM
rsmith committed rL302463: If we are building a module, and we read a second description of the same.
If we are building a module, and we read a second description of the same
Mon, May 8, 1:44 PM

Fri, May 5

rsmith committed rL302312: Permit keywords in module names in #pragma clang module *..
Permit keywords in module names in #pragma clang module *.
Fri, May 5, 3:47 PM
rsmith committed rL302309: Add support for building modules from preprocessed source..
Add support for building modules from preprocessed source.
Fri, May 5, 3:32 PM

Wed, May 3

rsmith committed rL302098: Add #pragma clang module begin/end pragmas and generate them when preprocessing….
Add #pragma clang module begin/end pragmas and generate them when preprocessing…
Wed, May 3, 5:43 PM

Tue, May 2

rsmith committed rL301992: [modules] Round-trip -Werror flag through explicit module build..
[modules] Round-trip -Werror flag through explicit module build.
Tue, May 2, 5:42 PM

Mon, May 1

rsmith committed rL301847: New file missed from r301846..
New file missed from r301846.
Mon, May 1, 3:24 PM
rsmith committed rL301846: Fix initial diagnostic state setup for an explicit module with no diagnostic….
Fix initial diagnostic state setup for an explicit module with no diagnostic…
Mon, May 1, 3:23 PM
rsmith committed rL301840: Put back REQUIRES: system-darwin to fix asan bot..
Put back REQUIRES: system-darwin to fix asan bot.
Mon, May 1, 3:03 PM
rsmith closed D32372: Arrays of unknown bound in constant expressions.
Mon, May 1, 12:03 PM
rsmith accepted D32372: Arrays of unknown bound in constant expressions.

Committed as r301822.

Mon, May 1, 12:03 PM
rsmith committed rL301822: Improve handling of arrays of unknown bound in constant expressions..
Improve handling of arrays of unknown bound in constant expressions.
Mon, May 1, 12:02 PM

Sun, Apr 30

rsmith accepted D32675: in expression evaluator, treat non-literal types as discarded value expressions if EvalInfo says to continue evaluating them.

Thanks. Could you also add something like:

Sun, Apr 30, 6:52 PM

Fri, Apr 28

rsmith committed rL301732: Remove some apparently-unnecessary 'REQUIRES: system-darwin' from tests..
Remove some apparently-unnecessary 'REQUIRES: system-darwin' from tests.
Fri, Apr 28, 6:51 PM
rsmith committed rL301731: Fix "REQUIRES: system-darwin" failing tests after r301725..
Fix "REQUIRES: system-darwin" failing tests after r301725.
Fri, Apr 28, 6:42 PM
rsmith committed rL301727: PR26771: don't forget the " 2" (returning from #included file) linemarker after….
PR26771: don't forget the " 2" (returning from #included file) linemarker after…
Fri, Apr 28, 6:07 PM
rsmith committed rL301726: Remove unused, empty test directories..
Remove unused, empty test directories.
Fri, Apr 28, 5:59 PM
rsmith added a comment to D32372: Arrays of unknown bound in constant expressions.

Thanks, this looks good, just a couple of minor things and then it should be ready to land.

Fri, Apr 28, 5:52 PM
rsmith committed rL301725: Add pragma to perform module import and use it in -E output..
Add pragma to perform module import and use it in -E output.
Fri, Apr 28, 5:48 PM
rsmith accepted D32566: Revert rL301328 and add tests for the regressions introduced..

Yes, let's first revert back to the clang 4.0 behavior, then please mail cfe-dev to discuss what the right behavior should be.

Fri, Apr 28, 4:55 PM · Restricted Project
rsmith accepted D32410: change the way the expr evaluator handles objcboxedexpr.

LGTM, thanks!

Fri, Apr 28, 4:38 PM

Thu, Apr 27

rsmith accepted D30427: Fix whitespace before token-paste of an argument..

LGTM

Thu, Apr 27, 7:50 PM
rsmith committed rL301610: Move functionality for handling module maps as inputs from the -emit-module.
Move functionality for handling module maps as inputs from the -emit-module
Thu, Apr 27, 7:02 PM
rsmith accepted D31856: Headers: Make the type of SIZE_MAX the same as size_t.
Thu, Apr 27, 3:20 PM
rsmith added a comment to D32566: Revert rL301328 and add tests for the regressions introduced..

I'm OK with this from a mechanical perspective. But there's also a libclang design question here: what should the libclang methods to query template arguments for a type cursor representing an alias template specialization actually do? Should there be some way for a libclang user to choose what result they get?

Thu, Apr 27, 12:31 AM · Restricted Project
rsmith accepted D32405: Expr evaluator may want to continue into ArraySubscriptExpr if evaluation mode indicates.

LGTM

Thu, Apr 27, 12:20 AM
rsmith added inline comments to D32410: change the way the expr evaluator handles objcboxedexpr.
Thu, Apr 27, 12:18 AM

Wed, Apr 26

rsmith accepted D32412: analyze all kinds of expressions for integer overflow.

If we're now catching integer overflow in more cases, please add some relevant testcases. If this is a pure refactoring that enables those additional diagnostics to be produced in future, then this is fine as-is. (For the benefit of other people looking at this, the test changes here are caused by a pre-existing bug: the notes for why a reference is not usable in a constant expression are only produced if we happen to produce diagnostics the first time we try to evaluate them.)

Wed, Apr 26, 11:56 PM
rsmith accepted D32455: detect integer overflow inside arms of conditional operator with non-constant expression.

LGTM

Wed, Apr 26, 11:48 PM
rsmith committed rL301507: Improve diagnostics for bad -std= flag..
Improve diagnostics for bad -std= flag.
Wed, Apr 26, 6:30 PM
rsmith committed rL301500: Remove unnecessary and somewhat inaccurate "C89" flag from language standards..
Remove unnecessary and somewhat inaccurate "C89" flag from language standards.
Wed, Apr 26, 5:03 PM
rsmith committed rL301497: Don't accept -std= values that would switch us to a different source language..
Don't accept -std= values that would switch us to a different source language.
Wed, Apr 26, 4:57 PM
rsmith committed rL301483: Update lldb to match clang r301442..
Update lldb to match clang r301442.
Wed, Apr 26, 3:23 PM
rsmith added a comment to D32348: [libclang] Check for a record declaration before a template specialization..

This change looks like it introduces a regression itself: given

Wed, Apr 26, 2:35 PM · Restricted Project
rsmith added a comment to D32372: Arrays of unknown bound in constant expressions.

The change in direction from diagnosing the lvalue-to-rvalue conversion to diagnosing the pointer arithmetic seems fine to me (and is likely a better approach overall), but this means we should now treat a designator referring to element 0 of an array of unknown / runtime bound as being valid. We have minimal support for this already for __builtin_object_size evaluation, which you should be able to generalize to support arbitrary designators ending with such a value.

Wed, Apr 26, 2:00 PM
rsmith committed rL301442: Refactor frontend InputKind to prepare for treating module maps as a distinct….
Refactor frontend InputKind to prepare for treating module maps as a distinct…
Wed, Apr 26, 12:10 PM
rsmith added inline comments to D31588: Fix PR25627: Certain constant local variables must be usable as template arguments (without being odr-used).
Wed, Apr 26, 11:37 AM

Mon, Apr 24

rsmith committed rL301285: Placate MSVC's narrowing conversion unhappiness..
Placate MSVC's narrowing conversion unhappiness.
Mon, Apr 24, 8:41 PM