summaryrefslogtreecommitdiffstats
path: root/Source/LexerParser/cmFortranParser.cxx
Commit message (Collapse)AuthorAgeFilesLines
* Fortran: Restore support for parsing "end interface X"Brad King2022-11-301-146/+156
| | | | | | | | | Since commit 219a9b1e14 (Fortran: Fix suprious dependencies with submodules, 2022-07-30, v3.25.0-rc1~327^2) we accidentally fail to recognize `end interface X`, causing all subsequent modules to be seen as an interface. Fixes: #24203
* Fortran: Fix suprious dependencies with submodulesVitaly Mogulian2022-08-091-180/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | In commit 695f0d0d3a (cmFortranParser: Parse keywords as lexical tokens, 2016-09-05, v3.7.0-rc1~150^2) we created keyword-specific variants of the original `USE WORD other EOSTMT` production, such as `MODULE WORD other EOSTMT` and `INTERFACE WORD other EOSTMT`. The same pattern was used by more keyword-specific productions in commit b5ac8b8aa7 (Fortran: Add support for submodule syntax in dependency scanning, 2016-09-05, v3.7.0-rc1~73^2~1). The postfix part (`other`) of several keyword-specific productions is not needed to match Fortran syntax. See the Fortran 2018 standard, para.4.1.4/1 on p.28, para.14.2.1/2 on pp.293-294. The postfix is needed only for a case of operator 'use': use <module-name> [, only : <list-of-vars>] The unnecessary postfix matching from the keyword-specific productions such as module, submodule, and interface declarations can cause spurious module dependencies to be detected, so remove it. Extend the test suite with examples covering the previously-broken cases. Fixes: #18427
* LexerParser: Suppress clang -Wunused-but-set-variable warningsBrad King2022-04-061-63/+68
|
* LexerParser: Regenerate parsers with bison 3.8.2Brad King2022-04-061-85/+73
|
* Makefiles: Add support for building Fortran intrinsicsIsuru Fernando2021-06-241-37/+41
| | | | Fixes: #21463
* LexerParser: Do not leak Fortran parser tokens discarded due to errorsBrad King2021-06-081-56/+78
|
* LexerParser: Regenerate parsers with bison 3.7.5Brad King2021-04-281-37/+49
|
* LexerParser: Suppress gcc -Wfree-nonheap-object warnings in generated codeBrad King2021-02-051-56/+57
|
* LexerParser: Clean up includes following include-what-you-useChristoph Grüninger2021-01-251-57/+56
|
* LexerParser: Regenerate parser files with GNU Bison 3.7.4Christoph Grüninger2021-01-251-508/+583
| | | | Adjust expected test output.
* Fortran: ignore CPP line directives in line-continued USE stmtsTiziano Müller2019-11-131-123/+123
| | | | Issue: #18188
* LexerParser: Regenerate parsers with bison 3.4.2Kitware Robot2019-11-131-62/+66
|
* LexerParser: Regenerate parsers with bison 3.3Brad King2019-07-221-148/+156
| | | | Run `Utilities/Scripts/regenerate-parsers.bash`.
* LexerParser: Suppress GCC -Wconversion warningsBrad King2018-07-311-59/+62
| | | | | GCC 8 warns about some of the conversions in bison-generated code. Suppress the warnings.
* Fortran: Add support for submodule dependenciesBrad King2018-04-201-2/+2
| | | | | | | | | | | | | | | | | | | | | Since commit v3.7.0-rc1~73^2~1 (Fortran: Add support for submodule syntax in dependency scanning, 2016-09-05) we support parsing Fortran sources that use submodule syntax, but it left addition of `.smod` dependencies to future work. Add it now. The syntax submodule (module_name) submodule_name means the current source requires `module_name.mod` and provides `module_name@submodule_name.smod`. The syntax submodule (module_name:submodule_name) nested_submodule_name means the current source requires `module_name@submodule_name.smod` provides `module_name@nested_submodule_name.smod`. Fixes: #17017
* LexerParser: move to custom directoryDaniel Pfeifer2017-04-281-0/+1988