Skip to content
Snippets Groups Projects
  1. Nov 13, 2014
  2. Nov 11, 2014
    • Manuel López-Ibáñez's avatar
      re PR fortran/44054 (Handle -Werror, -Werror=, -fdiagnostics-show-option,... · 3aa34c1d
      Manuel López-Ibáñez authored
      re PR fortran/44054 (Handle -Werror, -Werror=, -fdiagnostics-show-option, !GCC$ diagnostic (pragmas) and color)
      
      libcpp/ChangeLog:
      
      2014-11-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	PR fortran/44054
      	* include/line-map.h (linemap_position_for_loc_and_offset):
      	Declare.
      	* line-map.c (linemap_position_for_loc_and_offset): New.
      
      
      gcc/fortran/ChangeLog:
      
      2014-11-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	PR fortran/44054
      	* gfortran.h (warn_use_without_only): Remove.
      	(gfc_diagnostics_finish): Declare.
      	* error.c: Include tree-diagnostics.h
      	(gfc_format_decoder): New.
      	(gfc_diagnostics_init): Use gfc_format_decoder. Set default caret
      	char.
      	(gfc_diagnostics_finish): Restore tree diagnostics defaults, but
      	keep gfc_diagnostics_starter and finalizer. Restore default caret.
      	* options.c: Remove all uses of warn_use_without_only.
      	* lang.opt (Wuse-without-only): Add Var.
      	* f95-lang.c (gfc_be_parse_file): Call gfc_diagnostics_finish.
      	* module.c (gfc_use_module): Use gfc_warning_now_2.
      	* parse.c (decode_statement): Likewise.
      	(decode_gcc_attribute): Likewise.
      	(next_free): Likewise.
      	(next_fixed): Likewise.
      
      
      gcc/testsuite/ChangeLog:
      
      2014-11-11  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	PR fortran/44054
      	* lib/gfortran-dg.exp: Update regexp to match locus and message
      	without caret.
      	* gfortran.dg/use_without_only_1.f90: Add column numbers.
              * gfortran.dg/warnings_are_errors_1.f: Update.
      
      From-SVN: r217383
      3aa34c1d
    • David Malcolm's avatar
      Merger of dmalcolm/jit branch from git · 35485da9
      David Malcolm authored
      ChangeLog:
      	* ChangeLog.jit: New.
      	* MAINTAINERS (Various Maintainers): Add myself as jit maintainer.
      
      contrib/ChangeLog:
      	* ChangeLog.jit: New.
      	* jit-coverage-report.py: New file: a script to print crude
      	code-coverage information for the libgccjit API.
      
      gcc/ChangeLog:
      	* ChangeLog.jit: New.
      	* Makefile.in (doc_build_sys): New variable, set to "sphinx" if
      	sphinx is installed, falling back to "texinfo" otherwise.
      	(FULL_DRIVER_NAME): New variable, adapted from the
      	install-driver target.  New target, a symlink within the builddir,
      	linked to "xgcc", for use when running the JIT library from the
      	builddir.
      	(MOSTLYCLEANFILES): Add FULL_DRIVER_NAME.
      	(install-driver): Use $(FULL_DRIVER_NAME) rather than spelling it
      	out.
      	* configure.ac (doc_build_sys): New variable, set to "sphinx" if
      	sphinx is installed, falling back to "texinfo" otherwise.
      	(GCC_DRIVER_NAME): Generate a gcc-driver-name.h file containing
      	GCC_DRIVER_NAME for the benefit of jit/internal-api.c.
      	* configure: Regenerate.
      	* doc/install.texi (--enable-host-shared): Specify that this is
      	required when building libgccjit.
      	(Tools/packages necessary for modifying GCC): Add Sphinx.
      	* timevar.def (TV_JIT_REPLAY): New.
      	(TV_ASSEMBLE): New.
      	(TV_LINK): New.
      	(TV_LOAD): New.
      
      gcc/java/ChangeLog:
      	* gcc/ChangeLog.jit: New.
      
      gcc/jit/ChangeLog:
      	* ChangeLog.jit: New.
      	* ChangeLog: New.
      	* Make-lang.in: New.
      	* TODO.rst: New.
      	* config-lang.in: New.
      	* docs/Makefile: New.
      	* docs/_build/texinfo/Makefile: New.
      	* docs/_build/texinfo/factorial.png: New.
      	* docs/_build/texinfo/libgccjit.texi: New.
      	* docs/_build/texinfo/sum-of-squares.png: New.
      	* docs/conf.py: New.
      	* docs/examples/tut01-hello-world.c: New.
      	* docs/examples/tut02-square.c: New.
      	* docs/examples/tut03-sum-of-squares.c: New.
      	* docs/examples/tut04-toyvm/Makefile: New.
      	* docs/examples/tut04-toyvm/factorial.toy: New.
      	* docs/examples/tut04-toyvm/fibonacci.toy: New.
      	* docs/examples/tut04-toyvm/toyvm.c: New.
      	* docs/index.rst: New.
      	* docs/internals/index.rst: New.
      	* docs/intro/factorial.png: New.
      	* docs/intro/index.rst: New.
      	* docs/intro/sum-of-squares.png: New.
      	* docs/intro/tutorial01.rst: New.
      	* docs/intro/tutorial02.rst: New.
      	* docs/intro/tutorial03.rst: New.
      	* docs/intro/tutorial04.rst: New.
      	* docs/topics/contexts.rst: New.
      	* docs/topics/expressions.rst: New.
      	* docs/topics/functions.rst: New.
      	* docs/topics/index.rst: New.
      	* docs/topics/locations.rst: New.
      	* docs/topics/objects.rst: New.
      	* docs/topics/results.rst: New.
      	* docs/topics/types.rst: New.
      	* dummy-frontend.c: New.
      	* jit-builtins.c: New.
      	* jit-builtins.h: New.
      	* jit-common.h: New.
      	* jit-playback.c: New.
      	* jit-playback.h: New.
      	* jit-recording.c: New.
      	* jit-recording.h: New.
      	* libgccjit++.h: New.
      	* libgccjit.c: New.
      	* libgccjit.h: New.
      	* libgccjit.map: New.
      	* notes.txt: New.
      
      gcc/testsuite/ChangeLog:
      	* ChangeLog.jit: New.
      	* jit.dg/all-non-failing-tests.h: New.
      	* jit.dg/harness.h: New.
      	* jit.dg/jit.exp: New.
      	* jit.dg/test-accessing-struct.c: New.
      	* jit.dg/test-accessing-union.c: New.
      	* jit.dg/test-array-as-pointer.c: New.
      	* jit.dg/test-arrays.c: New.
      	* jit.dg/test-calling-external-function.c: New.
      	* jit.dg/test-calling-function-ptr.c: New.
      	* jit.dg/test-combination.c: New.
      	* jit.dg/test-dot-product.c: New.
      	* jit.dg/test-empty.c: New.
      	* jit.dg/test-error-accessing-field-in-other-struct.c: New.
      	* jit.dg/test-error-adding-to-terminated-block.c: New.
      	* jit.dg/test-error-array-as-pointer.c: New.
      	* jit.dg/test-error-bad-cast.c: New.
      	* jit.dg/test-error-block-in-wrong-function.c: New.
      	* jit.dg/test-error-call-through-ptr-with-mismatching-args.c: New.
      	* jit.dg/test-error-call-through-ptr-with-non-function.c: New.
      	* jit.dg/test-error-call-through-ptr-with-non-pointer.c: New.
      	* jit.dg/test-error-call-through-ptr-with-not-enough-args.c: New.
      	* jit.dg/test-error-call-through-ptr-with-too-many-args.c: New.
      	* jit.dg/test-error-call-with-mismatching-args.c: New.
      	* jit.dg/test-error-call-with-not-enough-args.c: New.
      	* jit.dg/test-error-call-with-too-many-args.c: New.
      	* jit.dg/test-error-dereference-field-of-non-pointer.c: New.
      	* jit.dg/test-error-dereference-read-of-non-pointer.c: New.
      	* jit.dg/test-error-get-type-bad-enum.c: New.
      	* jit.dg/test-error-index-not-a-numeric-type.c: New.
      	* jit.dg/test-error-mismatching-types-in-assignment.c: New.
      	* jit.dg/test-error-mismatching-types-in-call.c: New.
      	* jit.dg/test-error-missing-return.c: New.
      	* jit.dg/test-error-new-binary-op-bad-op.c: New.
      	* jit.dg/test-error-new-function-bad-kind.c: New.
      	* jit.dg/test-error-new-unary-op-bad-op.c: New.
      	* jit.dg/test-error-null-passed-to-api.c: New.
      	* jit.dg/test-error-return-within-void-function.c: New.
      	* jit.dg/test-error-unreachable-block.c: New.
      	* jit.dg/test-error-unterminated-block.c: New.
      	* jit.dg/test-error-value-not-a-numeric-type.c: New.
      	* jit.dg/test-expressions.c: New.
      	* jit.dg/test-factorial.c: New.
      	* jit.dg/test-fibonacci.c: New.
      	* jit.dg/test-functions.c: New.
      	* jit.dg/test-fuzzer.c: New.
      	* jit.dg/test-hello-world.c: New.
      	* jit.dg/test-linked-list.c: New.
      	* jit.dg/test-long-names.c: New.
      	* jit.dg/test-nested-contexts.c: New.
      	* jit.dg/test-nested-loops.c: New.
      	* jit.dg/test-operator-overloading.cc: New.
      	* jit.dg/test-quadratic.c: New.
      	* jit.dg/test-quadratic.cc: New.
      	* jit.dg/test-reading-struct.c: New.
      	* jit.dg/test-string-literal.c: New.
      	* jit.dg/test-sum-of-squares.c: New.
      	* jit.dg/test-threads.c: New.
      	* jit.dg/test-types.c: New.
      	* jit.dg/test-using-global.c: New.
      	* jit.dg/test-volatile.c: New.
      
      include/ChangeLog:
      	* ChangeLog.jit: New.
      
      libbacktrace/ChangeLog:
      	* ChangeLog.jit: New.
      
      libcpp/ChangeLog:
      	* ChangeLog.jit: New.
      
      libdecnumber/ChangeLog:
      	* ChangeLog.jit: New.
      
      libiberty/ChangeLog:
      	* ChangeLog.jit: New.
      
      zlib/ChangeLog:
      	* ChangeLog.jit: New.
      
      From-SVN: r217374
      35485da9
  3. Nov 10, 2014
    • Edward Smith-Rowland's avatar
      cpplib.h (cpp_callbacks): Add has_attribute. · 42fd12b1
      Edward Smith-Rowland authored
      libcpp:
      
      2014-11-10  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* include/cpplib.h (cpp_callbacks): Add has_attribute.
      	* internal.h (lexer_state): Add in__has_attribute__.
      	* directives.c (lex_macro_node): Prevent use of __has_attribute__
      	as a macro.
      	* expr.c (parse_has_attribute): New function; (eval_token): Look for
      	__has_attribute__ and route to parse_has_attribute.
      	* identifiers.c (_cpp_init_hashtable): Initialize n__has_attribute__.
      	* pch.c (cpp_read_state): Initialize n__has_attribute__.
      	* traditional.c (enum ls): Add ls_has_attribute, ls_has_attribute_close;
      	(_cpp_scan_out_logical_line): Attend to __has_attribute__.
      
      
      gcc/c-family:
      
      2014-11-10  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* c-cppbuiltin.c (__has_attribute, __has_cpp_attribute): New macros;
      	(__cpp_rtti, __cpp_exceptions): New macros for C++98;
      	(__cpp_range_based_for, __cpp_initializer_lists,
      	__cpp_delegating_constructors, __cpp_nsdmi,
      	__cpp_inheriting_constructors, __cpp_ref_qualifiers): New macros
      	for C++11; (__cpp_attribute_deprecated): Remove in favor of
      	__has_cpp_attribute.
      	* c-lex.c (cb_has_attribute): New callback CPP function;
      	(init_c_lex): Set has_attribute callback.
      
      
      gcc/testsuite:
      
      2014-11-10  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* g++.dg/cpp1y/feat-cxx11.C: Test new feature macros for C++98
      	and C++11; Test existence of __has_cpp_attribute;  Test C++11
      	attributes.
      	* g++.dg/cpp1y/feat-cxx11-neg.C: Ditto.
      	* g++.dg/cpp1y/feat-cxx14.C: Ditto and test for C++14 attributes.
      	* g++.dg/cpp1y/feat-cxx98.C: Test new feature macros for C++98.
      	* g++.dg/cpp1y/feat-cxx98-neg.C: Ditto.
      	* g++.dg/cpp1y/feat-neg.C: Test that __cpp_rtti, _cpp_exceptions
      	will be undefined for -fno-rtti -fno-exceptions.
      
      From-SVN: r217292
      42fd12b1
  4. Nov 07, 2014
  5. Nov 06, 2014
    • Joseph Myers's avatar
      Preserve original spellings of extended identifiers. · be5ffc59
      Joseph Myers authored
      This patch makes cpplib track the original spellings of extended
      identifiers, as well as the canonical UTF-8 version, in order to
      follow standard semantics properly without needing a convoluted and
      undocumented canonicalization in translation phase 1 (see bug 9449
      comments 39-46 regarding such a canonicalization).
      
      The spelling is tracked in cpp_identifier and cpp_macro_arg without
      making cpp_token any larger.  The original spelling is used for checks
      of duplicate macro definitions, stringizing (see the C++ tests added;
      this case is only an issue for C++ not C because C makes it
      implementation-defined whether a \ is inserted before the \ of a UCN
      in a string or character constant when stringizing, while C++ does
      not), pasting (relevant when the result is then stringized for C++)
      and when macro definitions are output as text (e.g. for -d options).
      
      Once a macro has been defined, only the original spelling of the
      argument names needs keeping in the argument list.  While it is being
      defined, however, both spellings are needed: the original one for
      subsequent saving for checks of duplicate macro definitions, and the
      canonical one which is the node marked specially to generate macro
      argument tokens rather than normal identifier tokens.  The buffer that
      is used to save the original values of the identifier tokens is
      changed so that it stores both those original values and a pointer to
      the canonical hash nodes, so that those canonical nodes can be found
      when their values need restoring after the macro definition has been
      parsed.
      
      I believe this covers the known standards issues in extended
      identifiers support (the remaining unimplemented C99 areas in GCC all
      being floating-point-related), except for C++ translation of extended
      characters to UCNs in phase 1 (which I have no plans to work on).
      There are however probably issues left with handling of extended
      identifiers in other places, as listed in
      <https://gcc.gnu.org/ml/gcc-patches/2014-11/msg00337.html> (those
      issues are generally the sort of thing that could be addressed as bugs
      outside development stage 1).  (The bulk of the potential issues Zack
      was concerned about in 2003-5, that resulted in extended identifiers
      being disabled in the absence of -fextended-identifiers, were
      effectively eliminated by the audit and fixes I did in 2009, however;
      that todo list reflects what was left over after that audit.)
      
      Bootstrapped with no regressions on x86_64-unknown-linux-gnu.
      
      libcpp:
      	* include/cpp-id-data.h (struct cpp_macro): Update comment
      	regarding parameters.
      	* include/cpplib.h (struct cpp_macro_arg, struct cpp_identifier):
      	Add spelling fields.
      	(struct cpp_token): Update comment on macro_arg.
      	* internal.h (_cpp_save_parameter): Add extra argument.
      	(_cpp_spell_ident_ucns): New declaration.
      	* lex.c (lex_identifier): Add SPELLING argument.  Set *SPELLING to
      	original spelling of identifier.
      	(_cpp_lex_direct): Update calls to lex_identifier.
      	(_cpp_spell_ident_ucns): New function, factored out of
      	cpp_spell_token.
      	(cpp_spell_token): Adjust FORSTRING argument semantics to return
      	original spelling of identifiers.  Use _cpp_spell_ident_ucns in
      	!FORSTRING case.
      	(_cpp_equiv_tokens): Check spellings of identifiers and macro
      	arguments are identical.
      	* macro.c (macro_arg_saved_data): New structure.
      	(paste_tokens): Use original spellings of identifiers from
      	cpp_spell_token.
      	(_cpp_save_parameter): Add argument SPELLING.  Save both canonical
      	node and its value.
      	(parse_params): Update calls to _cpp_save_parameter.
      	(lex_expansion_token): Save spelling of macro argument tokens.
      	(_cpp_create_definition): Extract canonical node from saved data.
      	(cpp_macro_definition): Use UCNs in spelling of macro name.  Use
      	original spellings of macro argument tokens and identifiers.
      	* traditional.c (scan_parameters): Update call to
      	_cpp_save_parameter.
      
      gcc:
      	* doc/invoke.texi (-std=c99, -std=c11): Don't refer to corner
      	cases of extended identifiers.
      
      gcc/testsuite:
      	* g++.dg/cpp/ucnid-2.C, g++.dg/cpp/ucnid-3.C,
      	gcc.dg/cpp/ucnid-11.c, gcc.dg/cpp/ucnid-12.c,
      	gcc.dg/cpp/ucnid-13.c, gcc.dg/cpp/ucnid-14.c,
      	gcc.dg/cpp/ucnid-15.c: New tests.
      
      From-SVN: r217202
      be5ffc59
  6. Nov 05, 2014
    • Joseph Myers's avatar
      Enable -fextended-identifiers by default. · 701cade1
      Joseph Myers authored
      As proposed at <https://gcc.gnu.org/ml/gcc/2014-11/msg00014.html>,
      this patch enables -fextended-identifiers by default for all standard
      versions including this feature (all C++ versions, C99 and above for
      C, but not C90 / C94 / gnu89 / preprocessing assembler).  It adds a
      couple of tests for areas where I previously noted testsuite coverage
      for extended identifiers was lacking, removes -fextended-identifiers
      from existing tests, adds -g to various such tests to verify that
      extended identifiers don't break debug info generation and removes the
      test that was only there to verify that the feature was off by
      default.
      
      The current state of the feature may not correspond exactly to any
      particular checklist from 2004/5 (see bug 9449) of what was wanted
      before enabling the feature by default, but I don't think it's any
      worse than plenty of other features supported by default before every
      corner case is fully functional, and think problems can readily be
      fixed incrementally.
      
      The following aspects of extended identifiers could still do with more
      work (and should be straightforward):
      
      * C -aux-info (output should use UCNs).
      
      * ObjC -gen-decls (output should use UCNs; associated diagnostics from
        the ObjC front end should use extended characters or UCNs as
        appropriate to the locale, via using %qE or identifier_to_locale).
      
      * Use DW_AT_use_UTF8 in DWARF-3 debug info for compilation units built
        with extended identifiers enabled (or unconditionally).
      
      * cpplib diagnostics (outputting characters or UCNs as appropriate
        depending on the locale, as done for identifiers in non-cpplib
        diagnostics).
      
      * C++ test for UCN linking with C and extern "C".
      
      * Check GDB support / file issues for support if needed.
      
      * Actual UTF-8 in identifiers (?).  (Be careful about not affecting
        performance for the normal fast path of lexing identifiers, if
        possible.)
      
      The following may be trickier:
      
      * cpplib spelling preservation (required to diagnose macro
        redefinition with different spellings of the same identifier in the
        definition or argument names; different spellings of the name of the
        macro itself are OK, however; also required for correct handling of
        multiple stringizing in C++); correct output for -d (UCNs), DWARF
        debug info for macros (UCNs), PCH and PCH tests.  (Spelling
        preservation is the issue that needs fixing to remove references to
        corner cases in the documentation of -std=c99 and -std=c11 and in
        c99status.html.)  The idea would be to add a second pointer to
        cpp_identifier that stores the original spelling (whether for
        extended identifiers only, or for all identifiers); this does not
        enlarge cpp_token because the resulting larger cpp_identifier
        structure is no bigger than cpp_string.
      
      * C++ translation of extended characters (including $@` and various
        control characters) to UCNs in phase 1 (note diagnostics thus
        needed, but not for C++11, for control characters in strings /
        character constants as those UCNs invalid); a likely implementation
        approach is to do translation when identifiers / strings / character
        constants are lexed, together with errors for stray $@` / control
        characters in program as not being valid UCNs in identifiers ($ only
        if not accepted in identifiers); note that this translation should
        not take place inside raw string literals.
      
      Bootstrapped with no regressions on x86_64-unknown-linux-gnu.
      
      libcpp:
      	PR preprocessor/9449
      	* init.c (lang_defaults): Enable extended identifiers for C++ and
      	C99-based standards.
      
      gcc:
      	PR preprocessor/9449
      	* doc/cpp.texi (Character sets, Tokenization)
      	(Implementation-defined behavior): Don't refer to UCNs in
      	identifiers requiring -fextended-identifiers.
      	* doc/cppopts.texi (-fextended-identifiers): Document as enabled
      	by default for C99 and later and C++.
      	* doc/invoke.texi (-std=c99, -std=c11): Don't refer to extended
      	identifiers needing -fextended-identifiers.
      
      gcc/testsuite:
      	PR preprocessor/9449
      	* lib/target-supports.exp (check_effective_target_ucn_nocache):
      	Don't use -fextended-identifiers.
      	* c-c++-common/cpp/normalize-3.c, c-c++-common/cpp/ucnid-2011-1.c,
      	g++.dg/cpp/ucn-1.C, g++.dg/cpp/ucnid-1.C, g++.dg/other/ucnid-1.C,
      	gcc.dg/cpp/normalize-1.c, gcc.dg/cpp/normalize-2.c,
      	gcc.dg/cpp/normalize-4.c: Don't use -fextended-identifiers.
      	* gcc.dg/cpp/ucnid-1.c: Don't use -fextended-identifiers.  Use
      	-g3.
      	* gcc.dg/cpp/ucnid-10.c, gcc.dg/cpp/ucnid-2.c,
      	gcc.dg/cpp/ucnid-3.c, gcc.dg/cpp/ucnid-4.c, gcc.dg/cpp/ucnid-5.c,
      	gcc.dg/cpp/ucnid-7.c, gcc.dg/cpp/ucnid-9.c,
      	gcc.dg/cpp/warn-normalized-1.c, gcc.dg/cpp/warn-normalized-2.c,
      	gcc.dg/cpp/warn-normalized-3.c: Don't use -fextended-identifiers.
      	* gcc.dg/ucnid-1.c, gcc.dg/ucnid-2.c, gcc.dg/ucnid-3.c,
      	gcc.dg/ucnid-4.c, gcc.dg/ucnid-5.c, gcc.dg/ucnid-6.c: Don't use
      	-fextended-identifiers.  Use -g.
      	* gcc.dg/ucnid-7.c, gcc.dg/ucnid-8.c: Don't use
      	-fextended-identifiers.
      	* gcc.dg/ucnid-9.c: Don't use -fextended-identifiers.  Use -g.
      	* gcc.dg/ucnid-10.c: Don't use -fextended-identifiers.
      	* gcc.dg/ucnid-11.c, gcc.dg/ucnid-12.c: Don't use
      	-fextended-identifiers.  Use -g.
      	* gcc.dg/ucnid-13.c: Don't use -fextended-identifiers.
      	* gcc.dg/cpp/ucnid-8.c: Remove test.
      	* gcc.dg/cpp/ucnid-10.c, gcc.dg/ucnid-14.c: New tests.
      
      From-SVN: r217144
      701cade1
  7. Oct 22, 2014
    • Alan Modra's avatar
      gengtype.h (obstack_chunk_alloc, [...]): Remove cast. · 19a9ba64
      Alan Modra authored
      gcc/
      	* gengtype.h (obstack_chunk_alloc, obstack_chunk_free): Remove cast.
      	* coretypes.h (obstack_chunk_alloc, obstack_chunk_free): Likewise.
      	(gcc_obstack_init): Use obstack_specify_allocation in place of
      	_obstack_begin.
      	* genautomata.c (next_sep_el): Cast result of obstack_base to (char *).
      	(regexp_representation): Likewise.
      	* godump.c (go_output_type): Likewise.
      gcc/java/
      	* mangle.c (finish_mangling): Cast result of obstack_base to (char *).
      	* typeck.c (build_java_argument_signature): Likewise.
      	(build_java_signature): Likewise.
      gcc/objc/
      	* objc-encoding.c (encode_array): Cast result of obstack_base.
      	(encode_type): Likewise.
      libcpp/
      	* symtab.c (ht_create): Use obstack_specify_allocation in place of
      	_obstack_begin.
      	* files.c (_cpp_init_files): Likewise.
      	* init.c (cpp_create_reader): Likewise.
      	* identifiers.c (_cpp_init_hashtable): Likewise.
      
      From-SVN: r216539
      19a9ba64
  8. Oct 14, 2014
    • Manuel López-Ibáñez's avatar
      line-map.h (linemap_location_from_macro_expansion_p): const struct line_maps * argument. · 3aac0952
      Manuel López-Ibáñez authored
      libcpp/ChangeLog:
      
      2014-10-14  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* include/line-map.h (linemap_location_from_macro_expansion_p):
      	const struct line_maps * argument.
      	(linemap_position_for_line_and_column): const struct line_map *
      	argument.
      	* line-map.c (linemap_add_macro_token): Use correct argument name
      	in comment.
      	(linemap_position_for_line_and_column): const struct line_map *
      	argument.
      	(linemap_macro_map_loc_to_def_point): Fix comment. Make static.
      	(linemap_location_from_macro_expansion_p): const struct line_maps *
      	argument.
      	(linemap_resolve_location): Fix argument names in comment.
      
      From-SVN: r216205
      3aac0952
  9. Oct 03, 2014
    • Bill Schmidt's avatar
      lex.c (search_line_fast): Add new version to be used for Power8 and later... · 0ccaaab0
      Bill Schmidt authored
      lex.c (search_line_fast): Add new version to be used for Power8 and later targets when Altivec is enabled.
      
      2014-10-03  Bill Schmidt  <wschmidt@linux.vnet.ibm.com>
      
      	* lex.c (search_line_fast): Add new version to be used for Power8
      	and later targets when Altivec is enabled.  Restrict the existing
      	Altivec version to big-endian systems so that lvsr is not used on
      	little endian, where it is deprecated.  Remove LE-specific code
      	from the now-BE-only version.
      
      From-SVN: r215873
      0ccaaab0
  10. Oct 02, 2014
  11. Oct 01, 2014
    • Edward Smith-Rowland's avatar
      Implement SD-6: SG10 Feature Test Recommendations · a15f7cb8
      Edward Smith-Rowland authored
      2014-10-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	Implement SD-6: SG10 Feature Test Recommendations
      	* internal.h (lexer_state, spec_nodes): Add in__has_include__.
      	* directives.c: Support __has_include__ builtin.
      	* expr.c (parse_has_include): New function to parse __has_include__
      	builtin; (eval_token()): Use it.
      	* files.c (_cpp_has_header()): New funtion to look for header;
      	(open_file_failed()): Not an error to not find a header file for
      	__has_include__.
      	* identifiers.c (_cpp_init_hashtable()): Add entry for __has_include__.
      	* pch.c (cpp_read_state): Lookup __has_include__.
      	* traditional.c (enum ls, _cpp_scan_out_logical_line()): Walk through
      	__has_include__ statements.
      
      2014-10-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	Implement SD-6: SG10 Feature Test Recommendations
      	* c-cppbuiltin.c (c_cpp_builtins()): Define language feature
      	macros and the __has_header macro.
      
      2014-10-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	Implement SD-6: SG10 Feature Test Recommendations
      	* include/bits/basic_string.h: Add __cpp_lib feature test macro.
      	* include/bits/stl_algobase.h: Ditto.
      	* include/bits/stl_function.h: Ditto.
      	* include/bits/unique_ptr.h: Ditto.
      	* include/std/chrono: Ditto.
      	* include/std/complex: Ditto.
      	* include/std/iomanip: Ditto.
      	* include/std/shared_mutex: Ditto.
      	* include/std/tuple: Ditto.
      	* include/std/type_traits: Ditto.
      	* include/std/utility: Ditto.
      	* testsuite/experimental/feat-cxx14.cc: New.
      	* testsuite/experimental/feat-lib-fund.cc: New.
      	* testsuite/20_util/declval/requirements/1_neg.cc: Adjust.
      	* testsuite/20_util/duration/literals/range.cc: Adjust.
      	* testsuite/20_util/duration/requirements/typedefs_neg1.cc: Adjust.
      	* testsuite/20_util/duration/requirements/typedefs_neg2.cc: Adjust.
      	* testsuite/20_util/duration/requirements/typedefs_neg3.cc: Adjust.
      	* testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust.
      	* testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc: Adjust.
      	* testsuite/23_containers/array/tuple_interface/get_neg.cc: Adjust.
      	* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
      	Adjust.
      
      2014-10-01  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	Implement SD-6: SG10 Feature Test Recommendations
      	* g++.dg/cpp1y/feat-cxx11-neg.C: New.
      	* g++.dg/cpp1y/feat-cxx11.C: New.
      	* g++.dg/cpp1y/feat-cxx14.C: New.
      	* g++.dg/cpp1y/feat-cxx98.C: New.
      	* g++.dg/cpp1y/feat-cxx98-neg.C: New.
      	* g++.dg/cpp1y/phoobhar.h: New.
      	* g++.dg/cpp1y/testinc/phoobhar.h: New.
      
      From-SVN: r215752
      a15f7cb8
  12. Sep 30, 2014
    • Bernd Edlinger's avatar
      re PR preprocessor/58893 (<command-line>:0:0: internal compiler error: Segmentation fault) · cc811a8a
      Bernd Edlinger authored
      2014-09-30  Bernd Edlinger  <bernd.edlinger@hotmail.de>
      
      	PR preprocessor/58893
      	* errors.c (cpp_diagnostic): Fix possible out of bounds access.
      	* files.c (_cpp_stack_include): Initialize src_loc for IT_CMDLINE.
      
      testsuite:
      2014-09-30  Bernd Edlinger  <bernd.edlinger@hotmail.de>
      
      	PR preprocessor/58893
      	* gcc.dg/pr58893.c: New test case.
      	* gcc.dg/pr58893-0.h: New include.
      
      From-SVN: r215730
      cc811a8a
  13. Sep 24, 2014
    • Marek Polacek's avatar
      re PR c/61405 (Not emitting "enumeration value not handled in switch" warning for bit-field enums) · 083e891e
      Marek Polacek authored
      	PR c/61405
      	PR c/53874
      gcc/
      	* asan.c (maybe_instrument_call): Add default case.
      	* ipa-pure-const.c (special_builtin_state): Likewise.
      	* predict.c (expr_expected_value_1): Likewise.
      	* lto-streamer-out.c (write_symbol): Initialize variable.
      gcc/c-family/
      	* c-common.h (struct c_common_resword): Don't define CPP_KEYWORD.
      gcc/c/
      	* c-parser.c: Don't define CPP_KEYWORD.
      	(c_parser_switch_statement): Pass original type to c_finish_case.
      	* c-tree.h (c_finish_case): Update declaration.
      	* c-typeck.c (c_finish_case): Add TYPE parameter.  Pass it
      	conditionally to c_do_switch_warnings.
      gcc/cp/
      	* semantics.c (finish_switch_cond): Call unlowered_expr_type.
      	* tree.c (bot_manip): Add default case.
      	* parser.c (cp_parser_primary_expression): Cast the controlling
      	expression of a switch to an int.
      	(cp_parser_unqualified_id): Likewise.
      gcc/testsuite/
      	* c-c++-common/pr53874.c: New test.
      	* c-c++-common/pr61405.c: New test.
      libcpp/
      	* include/cpplib.h (enum cpp_ttype): Define CPP_KEYWORD.
      
      From-SVN: r215559
      083e891e
  14. Sep 22, 2014
    • Jan Hubicka's avatar
      charset.c (conversion): Rename to ... · d87fc699
      Jan Hubicka authored
      	* charset.c (conversion): Rename to ...
      	(cpp_conversion): ... this one; update.
      	* files.c (file_hash_entry): Rename to ...
      	(cpp_file_hash_entry): ... this one ; update.
      
      From-SVN: r215482
      d87fc699
  15. Sep 17, 2014
    • Marek Polacek's avatar
      re PR c/61854 (Warning single-line comment for -std=c89?) · 909eb89c
      Marek Polacek authored
      	PR c/61854
      libcpp/
      	* init.c (struct lang_flags): Remove cplusplus_comments.
      	(cpp_set_lang): Likewise.
      	(post_options): Likewise.
      	* lex.c (_cpp_lex_direct): Disallow C++ style comments in C90/C94.
      testsuite/
      	* gcc.dg/cpp/pr61854-1.c: New test.
      	* gcc.dg/cpp/pr61854-2.c: New test.
      	* gcc.dg/cpp/pr61854-3.c: New test.
      	* gcc.dg/cpp/pr61854-3.h: New test.
      	* gcc.dg/cpp/pr61854-4.c: New test.
      	* gcc.dg/cpp/pr61854-5.c: New test.
      	* gcc.dg/cpp/pr61854-6.c: New test.
      	* gcc.dg/cpp/pr61854-7.c: New test.
      	* gcc.dg/cpp/pr61854-c90.c: New test.
      	* gcc.dg/cpp/pr61854-c94.c: New test.
      
      From-SVN: r215339
      909eb89c
  16. Sep 09, 2014
    • Manuel López-Ibáñez's avatar
      invoke.texi (Wnormalized=): Update. · 1ef33fd4
      Manuel López-Ibáñez authored
      gcc/ChangeLog:
      
      2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* doc/invoke.texi (Wnormalized=): Update.
      
      libcpp/ChangeLog:
      
      2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* include/cpplib.h (struct cpp_options): Declare warn_normalize as
      	int instead of enum.
      
      gcc/c-family/ChangeLog:
      
      2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* c.opt	(Wnormalized): New.
      	(Wnormalized=): Use Enum and Reject Negative.
      	* c-opts.c (c_common_handle_option): Do not handle Wnormalized here.
      
      gcc/testsuite/ChangeLog:
      
      2014-09-09  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* gcc.dg/cpp/warn-normalized-3.c: Delete useless dg-prune-output.
      
      From-SVN: r215093
      1ef33fd4
  17. Sep 04, 2014
    • Manuel López-Ibáñez's avatar
      options.texi: Document that Var and Init are required if CPP is given. · 2b71f4a4
      Manuel López-Ibáñez authored
      gcc/ChangeLog:
      
      2014-09-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* doc/options.texi: Document that Var and Init are required if CPP
      	is given.
      	* optc-gen.awk: Require Var and Init if CPP is given.
      	* common.opt (Wpedantic): Use Init.
      
      libcpp/ChangeLog:
      
      2014-09-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* macro.c (replace_args): Use cpp_pedwarning, cpp_warning and
      	CPP_W flags.
      	* include/cpplib.h: Add CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
      	* init.c (cpp_create_reader): Do not init to -1 here.
      	* expr.c (num_binary_op): Use cpp_pedwarning.
      
      gcc/c-family/ChangeLog:
      
      2014-09-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* c.opt (Wc90-c99-compat,Wc++-compat,Wcomment,Wendif-labels,
      	Winvalid-pch,Wlong-long,Wmissing-include-dirs,Wmultichar,Wpedantic,
      	(Wdate-time,Wtraditional,Wundef,Wvariadic-macros): Add CPP, Var
      	and Init.
      	* c-opts.c (c_common_handle_option): Do not handle here.
      	(sanitize_cpp_opts): Likewise.
      	* c-common.c (struct reason_option_codes_t): Handle
      	CPP_W_C90_C99_COMPAT and CPP_W_PEDANTIC.
      
      gcc/testsuite/ChangeLog:
      
      2014-09-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* gcc.dg/cpp/endif-pedantic2.c: More general options do not
      	override specific ones, but specific ones do.
      
      From-SVN: r214904
      2b71f4a4
  18. Aug 29, 2014
    • Manuel López-Ibáñez's avatar
      directives.c (check_eol_1): New. · 81b5d104
      Manuel López-Ibáñez authored
      libcpp/ChangeLog:
      
      2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* directives.c (check_eol_1): New.
      	(check_eol_endif_labels): New.
      	(check_eol): Call check_eol_1.
      	(do_else,do_endif): Call check_eol_endif_labels.
      
      gcc/c-family/ChangeLog:
      
      2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* c.opt (Wbuiltin-macro-redefined,Wdeprecated,Wendif-labels,
      	Winvalid-pch,Wliteral-suffix,Wmissing-include-dirs,Wtrigraphs,
      	Wundef): Use CPP, Var and Init.
      	* c-opts.c (c_common_handle_option): Do not handle the above flags here.
      
      From-SVN: r214735
      81b5d104
    • Manuel López-Ibáñez's avatar
      macro.c (warn_of_redefinition): Suppress warnings for builtins that lack the NODE_WARN flag... · b753b37b
      Manuel López-Ibáñez authored
      libcpp/ChangeLog:
      
      2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* macro.c (warn_of_redefinition): Suppress warnings for builtins
      	that lack the NODE_WARN flag, unless Wbuiltin-macro-redefined.
      	(_cpp_create_definition): Use Wbuiltin-macro-redefined for
      	builtins that lack the NODE_WARN flag.
      	* directives.c (do_undef): Likewise.
      	* init.c (cpp_init_special_builtins): Do not change flags
      	depending on Wbuiltin-macro-redefined.
      
      
      gcc/c-family/ChangeLog:
      
      2014-08-29  Manuel López-Ibáñez  <manu@gcc.gnu.org>
      
      	* c.opt (Wbuiltin-macro-redefined): Use CPP, Var and Init.
      	* c-opts.c (c_common_handle_option): Do not handle here.
      
      From-SVN: r214730
      b753b37b
  19. Aug 28, 2014
    • Edward Smith-Rowland's avatar
      PR cpp/23827 - standard C++ should not have hex float preprocessor · 7c05e50c
      Edward Smith-Rowland authored
      libcpp/
      
      2014-08-27  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	PR cpp/23827 - standard C++ should not have hex float preprocessor
      	tokens
      	* libcpp/init.c (lang_flags): Change CXX98 flag for extended numbers
      	from 1 to 0.
      	* libcpp/expr.c (cpp_classify_number): Weite error message for improper
      	use of hex floating literal.
      
      
      gcc/testsuite/
      
      2014-08-27  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	PR cpp/23827 - standard C++ should not have hex float preprocessor
      	tokens
      	* g++.dg/cpp/pr23827_cxx11.C: New.
      	* g++.dg/cpp/pr23827_cxx98.C: New.
      	* g++.dg/cpp/pr23827_cxx98_neg.C: New.
      	* gcc.dg/cpp/pr23827_c90.c: New.
      	* gcc.dg/cpp/pr23827_c90_neg.c: New.
      	* gcc.dg/cpp/pr23827_c99.c: New.
      
      From-SVN: r214616
      7c05e50c
  20. Aug 23, 2014
    • Edward Smith-Rowland's avatar
      cpplib.h (enum c_lang): Add CLK_GNUCXX1Z, CLK_CXX1Z... · e4276ba5
      Edward Smith-Rowland authored
      libcpp/
      
      2014-08-23  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* include/cpplib.h (enum c_lang): Add CLK_GNUCXX1Z, CLK_CXX1Z;
      	Rename CLK_GNUCXX1Y, CLK_CXX1Y to CLK_GNUCXX14, CLK_CXX14;
      	* init.c (struct lang_flags lang_defaults): Add column for trigraphs;
      	Add rows for CLK_GNUCXX1Z, CLK_CXX1Z; (cpp_set_lang): Set trigraphs;
      	(cpp_init_builtins): Set __cplusplus to 201402L for C++14;
      	Set __cplusplus to 201500L for C++17.
      	* expr.c (cpp_classify_number): Change C++1y to C++14 in binary
      	constants error message.
      
      
      gcc/c-family/
      
      2014-08-23  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* c-common.h (enum cxx_dialect): Add cxx14.
      	* c-opts.c (set_std_cxx1y): Rename to set_std_cxx14; Use cxx14.
      	* c-ubsan.c (ubsan_instrument_shift): Change comment and logic from
      	cxx_dialect == cxx11 || cxx_dialect == cxx1y to cxx_dialect >= cxx11.
      
      
      gcc/cp/
      
      2014-08-23  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* decl.c (compute_array_index_type, grokdeclarator,
      	undeduced_auto_decl): Change from cxx1y to cxx14.
      	*lambda.c(add_capture()): Change error message from C++1y to C++14.
      	* parser.c (cp_parser_unqualified_id, cp_parser_pseudo_destructor_name,
      	cp_parser_lambda_introducer, cp_parser_lambda_declarator_opt,
      	cp_parser_decltype, cp_parser_conversion_type_id,
      	cp_parser_simple_type_specifier, cp_parser_type_id_1,
      	cp_parser_template_type_arg, cp_parser_std_attribute,
      	cp_parser_template_declaration_after_export): Ditto.
      	* pt.c (tsubst): Ditto.
      	* semantics.c (force_paren_expr, finish_decltype_type): Ditto.
      	* tree.c: Change comment.
      	* typeck.c (comp_template_parms_position, cxx_sizeof_or_alignof_type,
      	cp_build_addr_expr_1, maybe_warn_about_useless_cast): Ditto.
      
      
      gcc/
      
      2014-08-23  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* doc/invoke.texi: Change c++1y to c++14 and gnu++1y to gnu++14.
      	Deprecate c++1y. Change language to reflect greater confidence in C++14.
      
      
      gcc/testsuite/
      
      2014-08-23  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	* g++.dg/cpp0x/cplusplus.C: New.
      	* g++.dg/cpp0x/cplusplus_0x.C: New.
      	* g++.dg/cpp0x/auto3.C: Change c++1y to c++14.
      	* g++.dg/cpp0x/auto41.C: Ditto.
      	* g++.dg/cpp0x/auto9.C: Ditto.
      	* g++.dg/cpp0x/initlist26.C: Ditto.
      	* g++.dg/cpp0x/pr59111.C: Ditto.
      	* g++.dg/cpp0x/trailing2.C: Ditto.
      	* g++.dg/cpp1y/attr-deprecated.C: Ditto.
      	* g++.dg/cpp1y/auto-dtor1.C: Ditto.
      	* g++.dg/cpp1y/auto-fn1.C: Ditto.
      	* g++.dg/cpp1y/auto-fn2.C: Ditto.
      	* g++.dg/cpp1y/auto-fn3.C: Ditto.
      	* g++.dg/cpp1y/auto-fn4.C: Ditto.
      	* g++.dg/cpp1y/auto-fn5.C: Ditto.
      	* g++.dg/cpp1y/auto-fn6.C: Ditto.
      	* g++.dg/cpp1y/auto-fn7.C: Ditto.
      	* g++.dg/cpp1y/auto-fn8.C: Ditto.
      	* g++.dg/cpp1y/auto-fn9.C: Ditto.
      	* g++.dg/cpp1y/auto-fn10.C: Ditto.
      	* g++.dg/cpp1y/auto-fn11.C: Ditto.
      	* g++.dg/cpp1y/auto-fn12.C: Ditto.
      	* g++.dg/cpp1y/auto-fn13.C: Ditto.
      	* g++.dg/cpp1y/auto-fn14.C: Ditto.
      	* g++.dg/cpp1y/auto-fn15.C: Ditto.
      	* g++.dg/cpp1y/auto-fn16.C: Ditto.
      	* g++.dg/cpp1y/auto-fn17.C: Ditto.
      	* g++.dg/cpp1y/auto-fn18.C: Ditto.
      	* g++.dg/cpp1y/auto-fn19.C: Ditto.
      	* g++.dg/cpp1y/auto-fn20.C: Ditto.
      	* g++.dg/cpp1y/auto-fn21.C: Ditto.
      	* g++.dg/cpp1y/auto-fn22.C: Ditto.
      	* g++.dg/cpp1y/auto-fn23.C: Ditto.
      	* g++.dg/cpp1y/auto-fn24.C: Ditto.
      	* g++.dg/cpp1y/auto-fn25.C: Ditto.
      	* g++.dg/cpp1y/auto-mangle1.C: Ditto.
      	* g++.dg/cpp1y/auto-neg1.C: Ditto.
      	* g++.dg/cpp1y/digit-sep.C: Ditto.
      	* g++.dg/cpp1y/digit-sep-neg.C: Ditto.
      	* g++.dg/cpp1y/digit-sep-cxx11-neg.C: Ditto.
      	* g++.dg/cpp1y/fn-generic-member-ool.C: Ditto.
      	* g++.dg/cpp1y/lambda-deduce-mult.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-cfun.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-dep.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-mixed.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-udt.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-variadic.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-vla1.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-x.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-xcfun.C: Ditto.
      	* g++.dg/cpp1y/lambda-generic-xudt.C: Ditto.
      	* g++.dg/cpp1y/lambda-init.C: Ditto.
      	* g++.dg/cpp1y/lambda-init1.C: Ditto.
      	* g++.dg/cpp1y/lambda-init2.C: Ditto.
      	* g++.dg/cpp1y/lambda-init3.C: Ditto.
      	* g++.dg/cpp1y/lambda-init4.C: Ditto.
      	* g++.dg/cpp1y/lambda-init5.C: Ditto.
      	* g++.dg/cpp1y/lambda-init6.C: Ditto.
      	* g++.dg/cpp1y/lambda-init7.C: Ditto.
      	* g++.dg/cpp1y/lambda-init8.C: Ditto.
      	* g++.dg/cpp1y/lambda-init9.C: Ditto.
      	* g++.dg/cpp1y/mangle1.C: Ditto.
      	* g++.dg/cpp1y/pr57640.C: Ditto.
      	* g++.dg/cpp1y/pr57644.C: Ditto.
      	* g++.dg/cpp1y/pr58500.C: Ditto.
      	* g++.dg/cpp1y/pr58533.C: Ditto.
      	* g++.dg/cpp1y/pr58534.C: Ditto.
      	* g++.dg/cpp1y/pr58535.C: Ditto.
      	* g++.dg/cpp1y/pr58536.C: Ditto.
      	* g++.dg/cpp1y/pr58548.C: Ditto.
      	* g++.dg/cpp1y/pr58549.C: Ditto.
      	* g++.dg/cpp1y/pr58637.C: Ditto.
      	* g++.dg/cpp1y/pr58708.C: Ditto.
      	* g++.dg/cpp1y/pr59110.C: Ditto.
      	* g++.dg/cpp1y/pr59112.C: Ditto.
      	* g++.dg/cpp1y/pr59113.C: Ditto.
      	* g++.dg/cpp1y/pr59629.C: Ditto.
      	* g++.dg/cpp1y/pr59635.C: Ditto.
      	* g++.dg/cpp1y/pr59636.C: Ditto.
      	* g++.dg/cpp1y/pr59638.C: Ditto.
      	* g++.dg/cpp1y/pr59867.C: Ditto.
      	* g++.dg/cpp1y/pr60033.C: Ditto.
      	* g++.dg/cpp1y/pr60052.C: Ditto.
      	* g++.dg/cpp1y/pr60053.C: Ditto.
      	* g++.dg/cpp1y/pr60054.C: Ditto.
      	* g++.dg/cpp1y/pr60064.C: Ditto.
      	* g++.dg/cpp1y/pr60065.C: Ditto.
      	* g++.dg/cpp1y/pr60190.C: Ditto.
      	* g++.dg/cpp1y/pr60311.C: Ditto.
      	* g++.dg/cpp1y/pr60332.C: Ditto.
      	* g++.dg/cpp1y/pr60376.C: Ditto.
      	* g++.dg/cpp1y/pr60377.C: Ditto.
      	* g++.dg/cpp1y/pr60384.C: Ditto.
      	* g++.dg/cpp1y/pr60390.C: Ditto.
      	* g++.dg/cpp1y/pr60391.C: Ditto.
      	* g++.dg/cpp1y/pr60393.C: Ditto.
      	* g++.dg/cpp1y/pr60573.C: Ditto.
      	* g++.dg/cpp1y/pr60626.C: Ditto.
      	* g++.dg/cpp1y/pr60627.C: Ditto.
      	* g++.dg/cpp1y/regress1.C: Ditto.
      	* g++.dg/cpp1y/system-binary-constants-1.C: Ditto.
      	* g++.dg/cpp1y/udlit-char-template.C: Ditto.
      	* g++.dg/cpp1y/udlit-char-template-neg.C: Ditto.
      	* g++.dg/cpp1y/udlit-empty-string-neg.C: Ditto.
      	* g++.dg/cpp1y/udlit-enc-prefix-neg.C: Ditto.
      	* g++.dg/cpp1y/udlit-userdef-string.C: Ditto.
      	* g++.dg/cpp1y/var-templ1.C: Ditto.
      	* g++.dg/cpp1y/var-templ2.C: Ditto.
      	* g++.dg/cpp1y/var-templ3.C: Ditto.
      	* g++.dg/cpp1y/var-templ4.C: Ditto.
      	* g++.dg/cpp1y/var-templ5.C: Ditto.
      	* g++.dg/cpp1y/var-templ6.C: Ditto.
      	* g++.dg/cpp1y/var-templ7.C: Ditto.
      	* g++.dg/cpp1y/vla1.C: Ditto.
      	* g++.dg/cpp1y/vla2.C: Ditto.
      	* g++.dg/cpp1y/vla3.C: Ditto.
      	* g++.dg/cpp1y/vla4.C: Ditto.
      	* g++.dg/cpp1y/vla5.C: Ditto.
      	* g++.dg/cpp1y/vla8.C: Ditto.
      	* g++.dg/cpp1y/vla9.C: Ditto.
      	* g++.dg/cpp1y/vla10.C: Ditto.
      	* g++.dg/cpp1y/vla11.C: Ditto.
      	* g++.dg/cpp1y/vla12.C: Ditto.
      	* g++.dg/cpp1y/vla13.C: Ditto.
      	* g++.dg/cpp1y/vla-initlist1.C: Ditto.
      	* g++.dg/ext/vector23.C: Ditto.
      	* g++.dg/ext/vla11.C: Ditto.
      	* gcc/testsuite/g++.dg/ubsan/cxx1y-vla.C: Ditto.
      	* g++.dg/warn/Wvla-2.C: Ditto.
      	* g++.dg/debug/dwarf2/auto1.C: Ditto.
      	* g++.dg/cpp1z/typename-tmpl-tmpl-parm-ped-neg.C: Ditto.
      	* g++.dg/cpp1y/cplusplus.C: Check for exact date.
      	* g++.dg/cpp1y/system-binary-constants-1.C: Check C++14 instead of C++1y
      	in error message.
      	* g++.dg/system-binary-constants-1.C: Ditto.
      	* g++.dg/cpp1y/cplusplus_1y.C: New.
      	* g++.dg/cpp1z/cplusplus.C: New.
      	* lib/target-supports.exp:
      	(check_effective_target_c++1y*): Rename to check_effective_target_c++14*
      	(check_effective_target_c++11_only): Call check_effective_target_c++14;
      	(check_effective_target_c++11_down): Ditto.
      
      From-SVN: r214400
      e4276ba5
  21. Aug 20, 2014
  22. Aug 19, 2014
    • Marek Polacek's avatar
      * lex.c (_cpp_lex_direct): Fix a typo. · 3f4f5c9a
      Marek Polacek authored
      From-SVN: r214166
      3f4f5c9a
    • Marek Polacek's avatar
      c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according to warn_c90_c99_compat. · 177cce46
      Marek Polacek authored
      gcc/c-family/
      	* c-opts.c (sanitize_cpp_opts): Make warn_long_long be set according
      	to warn_c90_c99_compat.
      	* c.opt (Wc90-c99-compat, Wdeclaration-after-statement): Initialize
      	to -1.
      gcc/c/
      	* c-decl.c (warn_variable_length_array): Pass OPT_Wvla unconditionally
      	to pedwarn_c90.
      	* c-errors.c: Include "opts.h".
      	(pedwarn_c90): Rewrite to handle -Wno-c90-c99-compat better.
      	* c-parser.c (disable_extension_diagnostics): Handle negative value
      	of warn_c90_c99_compat, too.
      	(restore_extension_diagnostics): Likewise.
      	(c_parser_compound_statement_nostart): Pass
      	OPT_Wdeclaration_after_statement unconditionally to pedwarn_c90.
      gcc/testsuite/
      	* gcc.dg/Wc90-c99-compat-4.c: Remove all dg-warnings.
      	* gcc.dg/Wc90-c99-compat-5.c: Remove all dg-errors.
      	* gcc.dg/Wc90-c99-compat-7.c: New test.
      	* gcc.dg/Wc90-c99-compat-8.c: New test.
      	* gcc.dg/Wdeclaration-after-statement-4.c: New test.
      libcpp/
      	* charset.c (_cpp_valid_ucn): Warn only if -Wc90-c99-compat.
      	* lex.c (_cpp_lex_direct): Likewise.
      	* macro.c (replace_args): Likewise.
      	(parse_params): Likewise.
      	* include/cpplib.h (cpp_options): Change cpp_warn_c90_c99_compat
      	to char.
      
      From-SVN: r214131
      177cce46
  23. Aug 10, 2014
    • Marek Polacek's avatar
      re PR c/51849 (-Wc99-compat would be considered useful) · f3bede71
      Marek Polacek authored
      	PR c/51849
      gcc/
      	* gcc/doc/invoke.texi: Document -Wc90-c99-compat.
      gcc/c-family/
      	* c-opts.c (sanitize_cpp_opts): Pass warn_c90_c99_compat to libcpp.
      	* c.opt (Wc90-c99-compat): Add option.
      gcc/c/
      	* c-decl.c (build_array_declarator): Remove check for !flag_isoc99.
      	Call pedwarn_c90 instead of pedwarn.
      	(check_bitfield_type_and_width): Likewise.
      	(declspecs_add_qual): Likewise.
      	(declspecs_add_type): Likewise.
      	(warn_variable_length_array): Unify function for -pedantic and -Wvla.
      	Adjust to only call pedwarn_c90.
      	(grokdeclarator): Remove pedantic && !flag_isoc99 check.  Call
      	pedwarn_c90 instead of pedwarn.
      	* c-errors.c (pedwarn_c90): Handle -Wc90-c99-compat.
      	* c-parser.c (disable_extension_diagnostics): Handle
      	warn_c90_c99_compat.
      	(restore_extension_diagnostics): Likewise.
      	(c_parser_enum_specifier): Remove check for !flag_isoc99.  Call
      	pedwarn_c90 instead of pedwarn.
      	(c_parser_initelt): Likewise.
      	(c_parser_postfix_expression): Likewise.
      	(c_parser_postfix_expression_after_paren_type): Likewise.
      	(c_parser_compound_statement_nostart): Remove check for !flag_isoc99.
      	* c-tree.h: Fix formatting.
      	* c-typeck.c (build_array_ref): Remove check for !flag_isoc99.  Call
      	pedwarn_c90 instead of pedwarn.
      gcc/testsuite/
      	* gcc.dg/Wc90-c99-compat-1.c: New test.
      	* gcc.dg/Wc90-c99-compat-2.c: New test.
      	* gcc.dg/Wc90-c99-compat-3.c: New test.
      	* gcc.dg/Wc90-c99-compat-4.c: New test.
      	* gcc.dg/Wc90-c99-compat-5.c: New test.
      	* gcc.dg/Wc90-c99-compat-6.c: New test.
      	* gcc.dg/wvla-1.c: Adjust dg-warning.
      	* gcc.dg/wvla-2.c: Adjust dg-warning.
      	* gcc.dg/wvla-4.c: Adjust dg-warning.
      	* gcc.dg/wvla-6.c: Adjust dg-warning.
      libcpp/
      	* lex.c (_cpp_lex_direct): Warn when -Wc90-c99-compat is in effect.
      	* charset.c (_cpp_valid_ucn): Likewise.
      	* include/cpplib.h (cpp_options): Add cpp_warn_c90_c99_compat.
      	* macro.c (replace_args): Warn when -Wc90-c99-compat is in effect.
      	(parse_params): Likewise.
      
      From-SVN: r213786
      f3bede71
  24. Jul 27, 2014
  25. Jul 16, 2014
    • Dodji Seketeli's avatar
      Support location tracking for built-in macro tokens · c468587a
      Dodji Seketeli authored
      
      When a built-in macro is expanded, the location of the token in the
      epansion list is the location of the expansion point of the built-in
      macro.
      
      This patch creates a virtual location for that token instead,
      effectively tracking locations of tokens resulting from built-in macro
      tokens.
      
      libcpp/
      	* include/line-map.h (line_maps::builtin_location): New data
      	member.
      	(line_map_init): Add a new parameter to initialize the new
      	line_maps::builtin_location data member.
      	* line-map.c (linemap_init): Initialize the
      	line_maps::builtin_location data member.
      	* macro.c (builtin_macro): Create a macro map and track the token
      	resulting from the expansion of a built-in macro.
      gcc/
      	* input.h (is_location_from_builtin_token): New function
      	declaration.
      	* input.c (is_location_from_builtin_token): New function
      	definition.
      	* toplev.c (general_init): Tell libcpp what the pre-defined
      	spelling location for built-in tokens is.
      
      Signed-off-by: default avatarDodji Seketeli <dodji@redhat.com>
      
      From-SVN: r212637
      c468587a
  26. Jul 11, 2014
  27. Jul 10, 2014
  28. Jul 09, 2014
    • Edward Smith-Rowland's avatar
      PR c++/58155 - -Wliteral-suffix warns about tokens which are skipped · 7aee8646
      Edward Smith-Rowland authored
      libcpp/
      
      2014-07-09  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	PR c++/58155 - -Wliteral-suffix warns about tokens which are skipped
      	by preprocessor
      	* lex.c (lex_raw_string ()): Do not warn about invalid suffix
      	if skipping. (lex_string ()): Ditto.
      
      
      gcc/testsuite/
      
      2014-07-09  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	PR c++/58155 - -Wliteral-suffix warns about tokens which are skipped
      	g++.dg/cpp0x/pr58155.C: New.
      
      From-SVN: r212392
      7aee8646
  29. Jun 05, 2014
  30. May 26, 2014
    • Richard Biener's avatar
      configure.ac: Remove long long and __int64 type checks... · edf6ddf6
      Richard Biener authored
      2014-05-26  Richard Biener  <rguenther@suse.de>
      
      	libcpp/
      	* configure.ac: Remove long long and __int64 type checks,
      	add check for uint64_t and fail if that wasn't found.
      	* include/cpplib.h (cpp_num_part): Use uint64_t.
      	* config.in: Regenerate.
      	* configure: Likewise.
      
      	gcc/
      	* configure.ac: Drop __int64 type check.  Insist that we
      	found uint64_t and int64_t.
      	* hwint.h (HOST_BITS_PER___INT64): Remove.
      	(HOST_BITS_PER_WIDE_INT): Define to 64 and remove
      	__int64 case.
      	(HOST_WIDE_INT_PRINT_*): Remove 32bit case.
      	(HOST_WIDEST_INT*): Define to HOST_WIDE_INT*.
      	(HOST_WIDEST_FAST_INT): Remove __int64 case.
      	* vmsdbg.h (struct _DST_SRC_COMMAND): Use int64_t
      	for dst_q_src_df_rms_cdt.
      	* configure: Regenerate.
      	* config.in: Likewise.
      
      From-SVN: r210928
      edf6ddf6
  31. May 21, 2014
  32. May 20, 2014
    • Richard Biener's avatar
      config.gcc: Remove need_64bit_hwint. · 54da09ee
      Richard Biener authored
      2014-05-20  Richard Biener  <rguenther@suse.de>
      
      	gcc/
      	* config.gcc: Remove need_64bit_hwint.
      	* configure.ac: Do not define NEED_64BIT_HOST_WIDE_INT.
      	* hwint.h: Do not check NEED_64BIT_HOST_WIDE_INT but assume
      	it to be true.
      	* config.in: Regenerate.
      	* configure: Likewise.
      
      	libcpp/
      	* configure.ac: Copy gcc logic of detecting a 64bit type.
      	Remove HOST_WIDE_INT define.
      	* include/cpplib.h: typedef cpp_num_part to a 64bit type,
      	similar to how hwint.h does it.
      	* config.in: Regenerate.
      	* configure: Likewise.
      
      From-SVN: r210632
      54da09ee
  33. May 09, 2014
  34. May 07, 2014
  35. Apr 22, 2014
    • Rainer Orth's avatar
      Remove obsolete Solaris 9 support · d9f069ab
      Rainer Orth authored
      	libstdc++-v3:
      	* configure.host: Remove solaris2.9 handling.
      	Change os_include_dir to os/solaris/solaris2.10.
      	* acinclude.m4 (ac_has_gthreads): Remove solaris2.9* handling.
      	* crossconfig.m4: Remove *-solaris2.9 handling, simplify.
      	* configure: Regenerate.
      	* config/abi/post/solaris2.9: Remove.
      	* config/os/solaris/solaris2.9: Rename to ...
      	* config/os/solaris/solaris2.10: ... this.
      	* config/os/solaris/solaris2.10/os_defines.h (CLOCK_MONOTONIC):
      	Remove.
      
      	* doc/xml/manual/configure.xml (--enable-libstdcxx-threads):
      	Remove Solaris 9 reference.
      	* doc/html/manual/configure.html: Regenerate.
      
      	* testsuite/27_io/basic_istream/extractors_arithmetic/char/12.cc:
      	Remove *-*-solaris2.9 xfail.
      	* testsuite/27_io/basic_istream/extractors_arithmetic/wchar_t/12.cc:
      	Likewise.
      
      	* testsuite/ext/enc_filebuf/char/13598.cc: Remove *-*-solaris2.9
      	xfail.
      
      	libjava:
      	* configure.ac (THREADLIBS, THREADSPEC): Remove *-*-solaris2.9
      	handling.
      	* configure: Regenerate.
      
      	libgfortran:
      	* config/fpu-387.h [__sun__ && __svr4__]: Remove SSE execution
      	check.
      
      	libgcc:
      	* config/i386/crtfastmath.c (set_fast_math): Remove SSE execution
      	check.
      	* config/i386/sol2-unwind.h (x86_fallback_frame_state): Remove
      	Solaris 9 single-threaded support.
      	* config/sparc/sol2-unwind.h (sparc64_is_sighandler): Remove
      	Solaris 9 single-threaded support.  Add call_user_handler code
      	sequences.
      	(sparc_is_sighandler): Likewise.
      
      	libcpp:
      	* lex.c: Remove Solaris 9 reference.
      
      	gcc/testsuite:
      	* gcc.c-torture/compile/pr28865.c: Remove dg-xfail-if.
      
      	* gcc.dg/c99-stdint-6.c: Remove dg-options for *-*-solaris2.9.
      	* gcc.dg/lto/20090210_0.c: Remove dg-extra-ld-options for
      	*-*-solaris2.9.
      	* gcc.dg/torture/pr47917.c: Remove dg-options for *-*-solaris2.9.
      	* gcc.target/i386/pr22076.c: Remove i?86-*-solaris2.9 handling
      	from dg-options.
      	* gcc.target/i386/pr22152.c: Remove i?86-*-solaris2.9 handling
      	from dg-additional-options.
      	* gcc.target/i386/vect8-ret.c: Remove i?86-*-solaris2.9 handling
      	from dg-options.
      
      	* gcc.dg/vect/tree-vect.h (check_vect): Remove Solaris 9 SSE2
      	execution check.
      	* gcc.target/i386/sse-os-support.h [__sun__ && __svr4__]
      	(sigill_hdlr): Remove.
      	(sse_os_support) [__sun__ && __svr4__]: Remove SSE execution
      	check.
      
      	* gfortran.dg/erf_3.F90: Remove sparc*-*-solaris2.9* handling.
      	* gfortran.dg/fmt_en.f90: Remove i?86-*-solaris2.9* handling.
      	* gfortran.dg/round_4.f90: Remove *-*-solaris2.9* handling.
      
      	* lib/target-supports.exp (add_options_for_tls): Remove
      	*-*-solaris2.9* handling.
      
      	gcc:
      	* config.gcc (enable_obsolete): Remove *-*-solaris2.9*.
      	(*-*-solaris2.[0-9] | *-*-solaris2.[0-9].*): Mark unsupported.
      	(*-*-solaris2*): Simplify.
      	(i[34567]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*): Likewise.
      	(i[34567]86-*-solaris2* | x86_64-*-solaris2.1[0-9]*): Remove
      	*-*-solaris2.9* handling.
      
      	* configure.ac (gcc_cv_as_hidden): Remove test for Solaris 9/x86
      	as bug.
      	(gcc_cv_ld_hidden): Remove *-*-solaris2.9* handling.
      	(ld_tls_support): Remove i?86-*-solaris2.9, sparc*-*-solaris2.9
      	handling, simplify.
      	(gcc_cv_as_gstabs_flag): Remove workaround for Solaris 9/x86 as bug.
      	* configure: Regenerate.
      
      	* config/i386/sol2-9.h: Remove.
      
      	* doc/install.texi (Specific, i?86-*-solaris2.9): Remove.
      	(Specific, *-*-solaris2*): Mention Solaris 9 support removal.
      	Remove Solaris 9 references.
      
      	fixincludes:
      	* inclhack.def (math_exception): Bypass on *-*-solaris2.1[0-9]*.
      	(solaris_int_types): Remove.
      	(solaris_longjmp_noreturn): Remove.
      	(solaris_mutex_init_2): Remove.
      	(solaris_once_init_2): Remove.
      	(solaris_sys_va_list): Remove.
      	* fixincl.x: Regenerate.
      	* tests/base/iso/setjmp_iso.h: Remove.
      	* tests/base/pthread.h [SOLARIS_MUTEX_INIT_2_CHECK]: Remove.
      	[SOLARIS_ONCE_INIT_1_CHECK]: Remove wrapping done by
      	solaris_once_init_2.
      	[SOLARIS_ONCE_INIT_2_CHECK]: Remove.
      	* tests/base/sys/int_types.h: Remove.
      	* tests/base/sys/va_list.h: Remove.
      
      	contrib:
      	* config-list.mk (LIST): Remove sparc-sun-solaris2.9, i686-solaris2.9.
      
      From-SVN: r209621
      d9f069ab
Loading