melges-morgen / gsoc-gcc-regex Goto Github PK
View Code? Open in Web Editor NEWRepository to work on the Regex in gcc
Repository to work on the Regex in gcc
The scanner skips, but should not, this expressions:
It needs to fail on patterns like "[c-a]" (which isn't valid).
Scanner fails on correct expressions like "[ca-]" which accepts "a", "c" and "-".
If you try to compile a regular expression \[a-z\] program send SIGSEGV.
Program received signal SIGSEGV, Segmentation fault.
0x000000000040b8b5 in __gnu_cxx::operator!=<std::__regex::_TokenFactory<std::regex_traits<char> > const*, std::vector<std::__regex::_TokenFactory<std::regex_traits<char> >, std::allocator<std::__regex::_TokenFactory<std::regex_traits<char> > > > > (
__lhs=<error reading variable: Cannot access memory at address 0x7fffff7feff8>,
__rhs=<error reading variable: Cannot access memory at address 0x7fffff7feff0>)
at /home/melges/Programs/gccRegexWorkspace/current-gcc-build/include/c++/4.8.0/bits/stl_iterator.h:825
825 operator!=(const __normal_iterator<_Iterator, _Container>& __lhs,
In backtrace more then 7000 calling to _M_alternative.
From libstdc++-v3/testsuite/28_regex/algorithms/01_compilation/01_basic_valid.cc:11
The same for (\[\[a-z\]\])*, (ss)s{s,s}\[dd\],
_M_scan_in_bracket failed on (([a-c])+) expression: after analysis of [a-c] token _M_curToken is _S_token_collem_single but _S_token_subexpr_end was expected.
UPD 13.07.12
_M_scan_in_bracket fails on [a-z-A-Z]
Add debuging stream, info http://gcc.gnu.org/onlinedocs/libstdc++/manual/debug_mode.html .
_M_scan_in_bracket must be able to handle expressions like this []].
Add ECMAScript support to _M_scan_in_bracket and _M_bracket_expression.
_Scanner<char const*>::_M_eat_escape fails on ((ss}}\a\s near \ and fails on ++?+??+?
Fails on a\{,4\}, a\{2,4\}, a\{2,\}.
Should all the scanner tokens be pre-cached? Right now, many of the tokens are using std::locale:: facets to get a result, and throwing away that locale-processed result. In other areas of the library, using locales without caching is slow.
Think about this issue from a design standpoint. At what point are things cached? What difference does it make? If we cannot measure any performance problems, then it doesn't make sense to measure it.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.