2
0
mirror of https://github.com/boostorg/wave.git synced 2026-01-19 04:42:16 +00:00
Commit Graph

193 Commits

Author SHA1 Message Date
Jeff Trull
465fe2291f Merge pull request #109 from jefftrull/feature/cpp20-tokens
Introduce C++20 tokens
2020-08-16 11:55:39 -07:00
Jeff Trull
200f91e71d Introduce C++20 tokens 2020-08-11 13:17:01 -07:00
Jeff Trull
add63677b0 C++11 tokens should be conditionally compiled 2020-08-10 05:10:07 -07:00
Jeff Trull
35fc5aa381 Add C++11 token support to all lexers
Support was already in slex, though it wasn't covered by the token
test. This updates the tests while adding virtually identical code
to lexertl and xlex.
2020-08-10 04:47:04 -07:00
Jeff Trull
9d68ca319a Track the location tokens were expanded from, for __LINE__ and __FILE__
An (optional) extra position field is added to token_data and set for
any identifier token created from a macro expansion. This information
is used to correctly calculate the filename and line number.
2020-07-20 20:51:14 -07:00
Jeff Trull
ee0a7c14c5 Implement __has_include() (#102)
Resolve #96 by introducing C++17 feature (and frequent vendor extension) __has_include(), along with appropriate unit tests and documentation updates
2020-06-27 07:22:52 -07:00
Jeff Trull
895ea836e9 Remove unused headers
Reduce build time by:
- using iosfwd instead of iostream, where possible
- where iostream is necessary but only used for debugging,
  making its inclusion conditional
- removing old C-style headers

I used IWYU to guide this work
2020-05-19 10:41:22 -07:00
Jeff Trull
3b6df8adb1 Include __LINE__, __FILE__, __INCLUDE_LEVEL__, and __VA_OPT__ in hooks (#87)
* Run hooks for certain predefined object-like macros

These are the "dynamic" macros with their own special execution path.
Most predefined macros can be computed at startup time; those were
already covered by the normal expansion code.

*  __VA_OPT__ is supported as a function-like macro

It is referred to as such in the proposal. __VA_ARGS__ is not supported, under the theory that it represents a parameter or set of parameters, and no hooks are called for parameter substitutions.
2020-04-12 12:40:03 -07:00
Jeff Trull
b68940a83b Disallow mixed-case long long integer literals (#80)
- Update all four lexers to allow ll/LL but not lL/Ll
- Add unit tests for checking
- Remove invalid token from test
2020-03-15 22:54:01 -07:00
Jeff Trull
849da9fb6a Remove linking to newly header-only date_time (#81)
Boost develop branch has an updated date_time that is header-only so
Wave's builds will now fail unless this dependency is removed.
2020-03-15 17:37:19 -07:00
Jeff Trull
750e0cb68c Repair lexertl lexer and add to test suite (#78)
- Update DFA index code to reflect newer Spirit versions
- Update corresponding static lexer, adding explanatory comments
- Incorporate lexertl into test framework
2020-03-13 12:24:49 -07:00
Jeff Trull
940071ed55 Repair xlex and add to test suite (#79)
* Pass tests by matching lexertl blank handling
* Remedial improvement to position tracking to avoid exception
* Fix token statistics sample's count map index calculation
* Add xlex to test suite

Also, prune includes somewhat.
2020-03-12 22:37:46 -07:00
Jeff Trull
ec0c8c8603 Implement C++20 features (#75)
* Introduce support for C++20 preprocessor features

- add __VA_OPT__ feature to variadic macros
- allow supplying 0 variadic arguments in more cases
- add related unit tests
2020-03-06 11:48:50 -08:00
Peter Dimov
5891614e84 Add quick.cpp test 2018-10-24 17:16:41 +03:00
Robert Lenhardt
e3680846ce fix utf8 testcases on non-windows systems 2018-10-06 12:41:23 +02:00
Robert Lenhardt
231aad085f add tests for utf-8 paths 2018-10-04 17:40:21 +02:00
Peter Dimov
4386cce02e Add test/Jamfile 2017-11-28 23:40:30 +02:00
Jeff Trull
c74492a208 Remove inadvertent newline from end of test file
Also tweak generated file to reflect source and avoid future speed bumps
2017-11-28 05:37:16 -08:00
Jeff Trull
1fde04d215 Repair C++11 raw string literal lexing, support custom delimiters, add tests 2017-11-27 19:26:11 -08:00
Hartmut Kaiser
10110a16b9 Fixing failing test on systems where BOOST_WAVE_SUPPORT_MS_EXTENSIONS is not defined 2017-10-19 16:23:19 -05:00
Abel Sinkovics
358a0e9668 Fix including header file without newline at the end 2017-09-18 22:25:52 +02:00
Abel Sinkovics
972461234d Fix reporting missing #endif when there is no new line after #if or #else 2017-09-18 22:02:57 +02:00
Abel Sinkovics
a53b51e440 Fix #line directive without new line at the end of a file 2017-09-17 15:35:37 +02:00
Abel Sinkovics
3c8b90bf60 Accept files with preprocessor directive in last line and no new line in C++11 mode. 2017-09-17 13:49:36 +02:00
Abel Sinkovics
4c4cc7e2ff Don't emit a warning about missing new line at end of file in C++11 mode 2017-09-16 22:49:30 +02:00
Abel Sinkovics
4474a5ce8c Add -Werror support 2017-09-16 22:49:22 +02:00
Hartmut Kaiser
baf1955439 Allow building testwave without separately instantiating grammars 2017-09-02 13:06:03 -05:00
Hartmut Kaiser
7dcb53aa80 Wave: fixed #8848: Wave driver improperly processes 0xFFFFui64 token
[SVN r85077]
2013-07-19 01:49:48 +00:00
Hartmut Kaiser
f83599b75b Wave: Fixed an obscure problem when preprocessing directives wouldn't be recognized if the previous line contained nothing but an empty macro invocation (see new test case t_9_023.cpp)
[SVN r79783]
2012-07-28 14:08:09 +00:00
Hartmut Kaiser
acb22f3fec Wave: reverting accidental commit
[SVN r79687]
2012-07-23 00:15:20 +00:00
Hartmut Kaiser
f441ea8aed Wave: Changed --c++0x command line option to --c++11.
[SVN r79685]
2012-07-22 23:12:11 +00:00
Hartmut Kaiser
56f4a8e7d2 Fixed #7159: Text-lines are processed as if they were preprocessing directives
[SVN r79684]
2012-07-22 23:08:25 +00:00
Hartmut Kaiser
e5ac1ca3b3 Wave: updating copyrights, minor fixes, bumping version number for release
[SVN r78555]
2012-05-23 14:41:35 +00:00
Hartmut Kaiser
ed79490930 Wave: Fixed #6838: Adding include file with force_include makes Wave fail to emit #line directive
Added support for test of --forceinclude option to testwave executable, added test case verifying #6838 is fixed.

[SVN r78554]
2012-05-23 14:38:10 +00:00
Hartmut Kaiser
5cd2912a6f Wave: Fixed whitespace handling, added a corresponding set of test cases
[SVN r69196]
2011-02-23 01:31:14 +00:00
Hartmut Kaiser
feb1e9ccdb Wave: updated copyrights, added C++0x mode to docs, added predefined macros for C++0x mode
[SVN r67894]
2011-01-09 22:19:16 +00:00
Hartmut Kaiser
12c91c34c1 Wave: updated copyrights, worked on whitespace skipping
[SVN r67893]
2011-01-09 21:54:54 +00:00
Hartmut Kaiser
582fd3f0ad Wave: fixing some path formatting issues causing test to fail
[SVN r67142]
2010-12-10 02:50:59 +00:00
Hartmut Kaiser
0a02b4bc4c Wave: fixed lexing errors introduced with the last commit, added new use case
[SVN r67118]
2010-12-09 03:01:33 +00:00
Hartmut Kaiser
55752997a3 Wave: more work on C++0x support, fixed a macro expansion problem
[SVN r67117]
2010-12-09 01:44:51 +00:00
Hartmut Kaiser
dc832745b7 Wave: fixing Wave for Boost Filesystem V3, which is now the default, changed build system for Wave tool to disable threading
[SVN r67093]
2010-12-08 01:29:47 +00:00
Hartmut Kaiser
56090535d3 Wave: adjusting code to pass new assert inspect rule
[SVN r66505]
2010-11-12 00:50:46 +00:00
Hartmut Kaiser
eb2d0881aa Wave: improved consistency in reporting skipped tokens to the hooks function when processing conditional preprocessing directives. Added a new test case verifying the skipped_token hook gets called reproducibly (t_2_020.cpp). Started to work on C++0x features for Wave.
[SVN r65314]
2010-09-05 22:33:20 +00:00
Hartmut Kaiser
1d5a9f46cb Wave: fixing regression test failures
[SVN r61381]
2010-04-18 20:29:54 +00:00
Hartmut Kaiser
1873625de5 Wave : fixing inspection errors
[SVN r61369]
2010-04-18 18:11:55 +00:00
Hartmut Kaiser
ffa289ff67 Wave: adjusting test files for recent bug fixes
[SVN r60829]
2010-03-25 17:41:29 +00:00
Hartmut Kaiser
b4c8d13ea6 Wave: minor comment edits
[SVN r59574]
2010-02-07 15:50:06 +00:00
Hartmut Kaiser
183f5cae8a Wave: added found_unknown_directive preprocessing hook
[SVN r59537]
2010-02-06 23:23:31 +00:00
Hartmut Kaiser
bbcad7c954 Wave: updating copyrights, fixing issues introduced by latest changes to multi_pass.
[SVN r58714]
2010-01-05 17:29:06 +00:00
Hartmut Kaiser
213d6495cb Minor fix to Jamfile.v2
[SVN r57413]
2009-11-05 17:39:13 +00:00