Commit Graph

204 Commits

Author SHA1 Message Date
ridiculousfish
7ac593273e Remove a bunch of dead code identified by cppcheck 2014-10-31 01:15:50 -07:00
ridiculousfish
a529fc9d83 Set of fixes for issues identified by cppcheck 2014-10-30 22:40:35 -07:00
ridiculousfish
5d1ddc9c58 Report certain errors from parser_t::eval() that were previously ignored 2014-10-12 20:09:45 -07:00
Kevin Ballard
3616dd5889 Base status -b off the parser execution stack
Instead of globally marking the state as "in block" when evaluating
blocks/functions, update the "in block" status when pushing/popping
blocks on the parser stack.

Fixes #1729.

On a side note, `status -b` is actually pretty useless, because it
always returns 0 inside of a function (even without this patch).
2014-09-30 20:58:45 -07:00
ridiculousfish
ee8e9c0291 Remove env_universal.h and env_universal.cpp from project 2014-06-18 10:14:35 -07:00
ridiculousfish
58ebdd4a7e Attempt to silence some warnings 2014-04-27 17:23:19 -07:00
ridiculousfish
8ed08872b9 Remove the now-unused parser_t::job_create 2014-04-14 12:40:17 -07:00
ridiculousfish
7a75e7341b Eliminate the parser_use_ast switch, which does nothing, and
exec_no_exec, which also does nothing in the new parser
2014-04-14 11:12:40 -07:00
ridiculousfish
0d3169ef70 Run restyle.sh to enforce style rules. 2014-03-31 10:01:39 -07:00
ridiculousfish
62b3ed17ba Teach parser_t how to parse an argument list that contains newlines, for
complete -a support. Fixes #1369
2014-03-27 11:17:05 -07:00
ridiculousfish
ad6367018b Excise use of parser_t's error() functionality. Thread a
parse_error_list_t through all of the expand functions, enabling them to
report errors more directly. Improve aspects of error reporting for
expansion failures.
2014-03-21 17:13:33 -07:00
ridiculousfish
c71b168402 Remove current_tokenizer and current_tokenizer_pos from old parser 2014-03-20 21:32:03 -07:00
ridiculousfish
4deb46290d Remove additional dead code from old parser 2014-03-20 21:32:03 -07:00
ridiculousfish
e5ef45e4c0 Rewrite parser_t::test_args and parser_t::eval_args to use new parser 2014-03-20 21:32:02 -07:00
ridiculousfish
1c58b6d83e Rewrite parser_t::eval_args to use new AST parser 2014-03-20 21:32:02 -07:00
ridiculousfish
1305c02579 Rewrite parser_t::current_line() to respect new parser 2014-03-20 21:32:02 -07:00
ridiculousfish
3cfdc6d126 Fix line number reporting in new parser 2014-03-20 21:32:02 -07:00
ridiculousfish
8ec73b2dd4 Removing some variables from parser_t that are no longer used in the new
execution model
2014-03-20 21:32:02 -07:00
ridiculousfish
5c54ef7b0d Merge branch 'master' into parser_cleanup 2014-03-15 20:24:25 -07:00
ridiculousfish
6c096191ba Remove support for invoking old pager 2014-03-15 13:46:15 -07:00
ridiculousfish
20f9dd9a6b Fix for extra newline that gets appended if a command is not found in
the new parser
2014-03-15 13:07:19 -07:00
ridiculousfish
cc12225142 Clean up various block types and state as part of new parser 2014-03-02 13:46:30 -08:00
ridiculousfish
6b3a37c597 Remove obviated builtins and additional cleanup of old parser 2014-03-02 13:11:17 -08:00
ridiculousfish
b187125b63 Merge branch 'master' into parser_cleanup 2014-03-01 20:33:26 -08:00
ridiculousfish
d232a0f951 Implement status -n (line number) with new parser 2014-03-01 16:04:13 -08:00
ridiculousfish
84ea96f383 Begin removing remnants of old parser 2014-02-28 20:01:04 -08:00
ridiculousfish
be33d3f2a4 Revert "Merge pull request #1317 from pullreq/cpp"
This reverts commit 74135c0600, reversing
changes made to 6d749789ce.

See discussion in #1317
2014-02-28 02:16:48 -08:00
ridiculousfish
0e991c596f Enable new parser by default (!). Fixes #557.
This entirely replaces fish's execution model. Bugs are likely. See commit 290aae80 for what this is about.
2014-02-27 21:06:39 -08:00
Geoff Nixon
18dd6f58e3 Fixes .c -> .cpp in comments. For doxygen. 2014-02-27 06:23:40 -08:00
Geoff Nixon
ddcd2b0810 Dead stores 2014-02-27 06:23:40 -08:00
ridiculousfish
de2eea05b4 Turn on the new pager by default, as described in #291 2014-02-22 22:24:23 -08:00
ridiculousfish
adf5b036d6 Fix to stop reporting config.fish execution as coming from "standard
input" within backtraces
2014-02-20 10:57:13 -08:00
ridiculousfish
2e1024d275 Tweak error reporting in new parser to use fewer lines 2014-02-17 14:52:08 -08:00
ridiculousfish
414530c9c2 Partially rework profiling. Fix profiling crash with new parser. Fixes
1295
2014-02-09 14:04:43 -08:00
ridiculousfish
0fbddb0df1 Add fish_new_pager variable to enable new pager on request, disabled by default. 2014-01-24 18:10:42 -08:00
ridiculousfish
53814983ff Update style and formatting to conform to fish style guide. 2014-01-15 01:40:40 -08:00
ridiculousfish
6fc1d7dc77 Further cleanup and improvements to error messages 2014-01-13 03:57:59 -08:00
ridiculousfish
95f87cdd56 Support for special && and || error messages in new parser 2014-01-13 02:24:11 -08:00
ridiculousfish
51c18e3f9a Turn off new parser for execution by default in preparation for merge
with trunk
2014-01-13 00:05:43 -08:00
ridiculousfish
096f850433 Eliminate class parse_t 2014-01-12 22:39:12 -08:00
ridiculousfish
1130e4782d Remove some unused defines 2014-01-12 00:11:29 -08:00
ridiculousfish
b34721b3f4 Miscellaneous optimizations to reduce string copying 2014-01-07 14:57:58 -08:00
ridiculousfish
993148552e Support for Ctrl-C cancellation in new parser. Added tests for it too. 2014-01-02 16:19:33 -08:00
ridiculousfish
fb882f0b69 Support for stack overflow and infinite recursion detection in new
parser
2014-01-01 15:29:56 -08:00
ridiculousfish
7356a0f6c8 Clean up and rationalize error handling in parse_execution.cpp 2013-12-31 14:37:37 -08:00
ridiculousfish
a9787b769f Support for implicit cd, no-exec, and the exit builtin. All tests now
pass (!). Error reporting still unsteady.
2013-12-29 16:23:26 -08:00
ridiculousfish
a42711e31c Support for break/continue with new parser execution 2013-12-28 22:52:06 -08:00
ridiculousfish
c632307eaa Make eval_node_at_offset return an error indication instead of the exit
status of the last command
2013-12-28 16:33:26 -08:00
ridiculousfish
0f9de11a67 Fix issues related to redirections and block level IO with new parser 2013-12-28 16:18:38 -08:00
ridiculousfish
6ce4b344e4 Hook up for statements, if statements, and function definition in new
parser
2013-12-27 01:38:43 -08:00