summaryrefslogtreecommitdiffstats
path: root/lld/ELF/ScriptLexer.h
Commit message (Collapse)AuthorAgeFilesLines
* [Coding style change] Rename variables so that they start with a lowercase ↵Rui Ueyama2019-07-101-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | letter This patch is mechanically generated by clang-llvm-rename tool that I wrote using Clang Refactoring Engine just for creating this patch. You can see the source code of the tool at https://reviews.llvm.org/D64123. There's no manual post-processing; you can generate the same patch by re-running the tool against lld's code base. Here is the main discussion thread to change the LLVM coding style: https://lists.llvm.org/pipermail/llvm-dev/2019-February/130083.html In the discussion thread, I proposed we use lld as a testbed for variable naming scheme change, and this patch does that. I chose to rename variables so that they are in camelCase, just because that is a minimal change to make variables to start with a lowercase letter. Note to downstream patch maintainers: if you are maintaining a downstream lld repo, just rebasing ahead of this commit would cause massive merge conflicts because this patch essentially changes every line in the lld subdirectory. But there's a remedy. clang-llvm-rename tool is a batch tool, so you can rename variables in your downstream repo with the tool. Given that, here is how to rebase your repo to a commit after the mass renaming: 1. rebase to the commit just before the mass variable renaming, 2. apply the tool to your downstream repo to mass-rename variables locally, and 3. rebase again to the head. Most changes made by the tool should be identical for a downstream repo and for the head, so at the step 3, almost all changes should be merged and disappear. I'd expect that there would be some lines that you need to merge by hand, but that shouldn't be too many. Differential Revision: https://reviews.llvm.org/D64121 llvm-svn: 365595
* Update the file headers across all of the LLVM projects in the monorepoChandler Carruth2019-01-191-4/+3
| | | | | | | | | | | | | | | | | to reflect the new license. We understand that people may be surprised that we're moving the header entirely to discuss the new license. We checked this carefully with the Foundation's lawyer and we believe this is the correct approach. Essentially, all code in the project is now made available by the LLVM project under our new license, so you will see that the license headers include that license only. Some of our contributors have contributed code under our old license, and accordingly, we have retained a copy of our old license notice in the top-level files in each project and repository. llvm-svn: 351636
* [LLD][ELD] - Do not reject INFO output section type when used with a start ↵George Rimar2018-08-281-0/+1
| | | | | | | | | | | | | | | | | | | | address. This is https://bugs.llvm.org/show_bug.cgi?id=38625 LLD accept this: ".stack (INFO) : {", but not this: ".stack address_expression (INFO) :" The patch fixes it. Differential revision: https://reviews.llvm.org/D51027 llvm-svn: 340804
* Move new lld's code to Common subdirectory.Rui Ueyama2017-10-021-1/+1
| | | | | | | | | | New lld's files are spread under lib subdirectory, and it isn't easy to find which files are actually maintained. This patch moves maintained files to Common subdirectory. Differential Revision: https://reviews.llvm.org/D37645 llvm-svn: 314719
* [ELF] - Remove ScriptLexer::Error field and check ErrorCount instead.George Rimar2017-08-041-1/+0
| | | | | | | | | | | | D35945 introduces change when there is useless to check Error flag in few places, but ErrorCount must be checked instead. But then we probably can just check ErrorCount always. That should simplify things. Patch do that. Differential revision: https://reviews.llvm.org/D36266 llvm-svn: 310046
* Handle ":" as a regular token character in linker scripts.Rui Ueyama2017-03-091-1/+2
| | | | | | | | | This is an alternative to https://reviews.llvm.org/D30500 to simplify the version definition parser and allow ":" in symbol names. Differential Revision: https://reviews.llvm.org/D30722 llvm-svn: 297402
* Apply different tokenization rules to linker script expressions.Rui Ueyama2017-02-151-0/+2
| | | | | | | | | | | | | | | | The linker script lexer is context-sensitive. In the regular context, arithmetic operator characters are regular characters, but in the expression context, they are independent tokens. This afects how the lexer tokenizes "3*4", for example. (This kind of expression is real; the Linux kernel uses it.) This patch defines function `maybeSplitExpr`. This function splits the current token into multiple expression tokens if the lexer is in the expression context. Differential Revision: https://reviews.llvm.org/D29963 llvm-svn: 295225
* Rename ScriptParser.{cpp,h} -> ScriptLexer.{cpp,h}.Rui Ueyama2017-02-141-0/+53
These files contain a lexer, so the new names are better. The parser is in LinkerScript.{cpp,h}. llvm-svn: 295022
OpenPOWER on IntegriCloud