1 /* C language support routines for GDB, the GNU debugger.
3 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2002,
4 2003, 2004, 2005 Free Software Foundation, Inc.
6 This file is part of GDB.
8 This program is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2 of the License, or
11 (at your option) any later version.
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 59 Temple Place - Suite 330,
21 Boston, MA 02111-1307, USA. */
26 #include "expression.h"
27 #include "parser-defs.h"
31 #include "macroscope.h"
32 #include "gdb_assert.h"
34 #include "gdb_string.h"
36 #include "cp-support.h"
38 extern void _initialize_c_language (void);
39 static void c_emit_char (int c
, struct ui_file
* stream
, int quoter
);
41 /* Print the character C on STREAM as part of the contents of a literal
42 string whose delimiter is QUOTER. Note that that format for printing
43 characters and strings is language specific. */
46 c_emit_char (int c
, struct ui_file
*stream
, int quoter
)
51 c
&= 0xFF; /* Avoid sign bit follies */
53 escape
= c_target_char_has_backslash_escape (c
);
56 if (quoter
== '"' && strcmp (escape
, "0") == 0)
57 /* Print nulls embedded in double quoted strings as \000 to
59 fprintf_filtered (stream
, "\\000");
61 fprintf_filtered (stream
, "\\%s", escape
);
63 else if (target_char_to_host (c
, &host_char
)
64 && host_char_print_literally (host_char
))
66 if (host_char
== '\\' || host_char
== quoter
)
67 fputs_filtered ("\\", stream
);
68 fprintf_filtered (stream
, "%c", host_char
);
71 fprintf_filtered (stream
, "\\%.3o", (unsigned int) c
);
75 c_printchar (int c
, struct ui_file
*stream
)
77 fputc_filtered ('\'', stream
);
78 LA_EMIT_CHAR (c
, stream
, '\'');
79 fputc_filtered ('\'', stream
);
82 /* Print the character string STRING, printing at most LENGTH characters.
83 LENGTH is -1 if the string is nul terminated. Each character is WIDTH bytes
84 long. Printing stops early if the number hits print_max; repeat counts are
85 printed as appropriate. Print ellipses at the end if we had to stop before
86 printing LENGTH characters, or if FORCE_ELLIPSES. */
89 c_printstr (struct ui_file
*stream
, const bfd_byte
*string
,
90 unsigned int length
, int width
, int force_ellipses
)
93 unsigned int things_printed
= 0;
97 /* If the string was not truncated due to `set print elements', and
98 the last byte of it is a null, we don't print that, in traditional C
102 && (extract_unsigned_integer (string
+ (length
- 1) * width
, width
)
108 fputs_filtered ("\"\"", stream
);
112 for (i
= 0; i
< length
&& things_printed
< print_max
; ++i
)
114 /* Position of the character we are examining
115 to see whether it is repeated. */
117 /* Number of repetitions we have detected so far. */
119 unsigned long current_char
;
125 fputs_filtered (", ", stream
);
129 current_char
= extract_unsigned_integer (string
+ i
* width
, width
);
134 && extract_unsigned_integer (string
+ rep1
* width
, width
)
141 if (reps
> repeat_count_threshold
)
146 fputs_filtered ("\\\", ", stream
);
148 fputs_filtered ("\", ", stream
);
151 LA_PRINT_CHAR (current_char
, stream
);
152 fprintf_filtered (stream
, _(" <repeats %u times>"), reps
);
154 things_printed
+= repeat_count_threshold
;
162 fputs_filtered ("\\\"", stream
);
164 fputs_filtered ("\"", stream
);
167 LA_EMIT_CHAR (current_char
, stream
, '"');
172 /* Terminate the quotes if necessary. */
176 fputs_filtered ("\\\"", stream
);
178 fputs_filtered ("\"", stream
);
181 if (force_ellipses
|| i
< length
)
182 fputs_filtered ("...", stream
);
185 /* Create a fundamental C type using default reasonable for the current
188 Some object/debugging file formats (DWARF version 1, COFF, etc) do not
189 define fundamental types such as "int" or "double". Others (stabs or
190 DWARF version 2, etc) do define fundamental types. For the formats which
191 don't provide fundamental types, gdb can create such types using this
194 FIXME: Some compilers distinguish explicitly signed integral types
195 (signed short, signed int, signed long) from "regular" integral types
196 (short, int, long) in the debugging information. There is some dis-
197 agreement as to how useful this feature is. In particular, gcc does
198 not support this. Also, only some debugging formats allow the
199 distinction to be passed on to a debugger. For now, we always just
200 use "short", "int", or "long" as the type name, for both the implicit
201 and explicitly signed types. This also makes life easier for the
202 gdb test suite since we don't have to account for the differences
203 in output depending upon what the compiler and debugging format
204 support. We will probably have to re-examine the issue when gdb
205 starts taking its fundamental type information directly from the
206 debugging information supplied by the compiler. fnf@cygnus.com */
209 c_create_fundamental_type (struct objfile
*objfile
, int typeid)
211 struct type
*type
= NULL
;
216 /* FIXME: For now, if we are asked to produce a type not in this
217 language, create the equivalent of a C integer type with the
218 name "<?type?>". When all the dust settles from the type
219 reconstruction work, this should probably become an error. */
220 type
= init_type (TYPE_CODE_INT
,
221 TARGET_INT_BIT
/ TARGET_CHAR_BIT
,
222 0, "<?type?>", objfile
);
223 warning (_("internal error: no C/C++ fundamental type %d"), typeid);
226 type
= init_type (TYPE_CODE_VOID
,
227 TARGET_CHAR_BIT
/ TARGET_CHAR_BIT
,
231 type
= init_type (TYPE_CODE_BOOL
,
232 TARGET_CHAR_BIT
/ TARGET_CHAR_BIT
,
236 type
= init_type (TYPE_CODE_INT
,
237 TARGET_CHAR_BIT
/ TARGET_CHAR_BIT
,
238 TYPE_FLAG_NOSIGN
, "char", objfile
);
241 type
= init_type (TYPE_CODE_INT
,
242 TARGET_CHAR_BIT
/ TARGET_CHAR_BIT
,
243 0, "signed char", objfile
);
245 case FT_UNSIGNED_CHAR
:
246 type
= init_type (TYPE_CODE_INT
,
247 TARGET_CHAR_BIT
/ TARGET_CHAR_BIT
,
248 TYPE_FLAG_UNSIGNED
, "unsigned char", objfile
);
251 type
= init_type (TYPE_CODE_INT
,
252 TARGET_SHORT_BIT
/ TARGET_CHAR_BIT
,
253 0, "short", objfile
);
255 case FT_SIGNED_SHORT
:
256 type
= init_type (TYPE_CODE_INT
,
257 TARGET_SHORT_BIT
/ TARGET_CHAR_BIT
,
258 0, "short", objfile
); /* FIXME-fnf */
260 case FT_UNSIGNED_SHORT
:
261 type
= init_type (TYPE_CODE_INT
,
262 TARGET_SHORT_BIT
/ TARGET_CHAR_BIT
,
263 TYPE_FLAG_UNSIGNED
, "unsigned short", objfile
);
266 type
= init_type (TYPE_CODE_INT
,
267 TARGET_INT_BIT
/ TARGET_CHAR_BIT
,
270 case FT_SIGNED_INTEGER
:
271 type
= init_type (TYPE_CODE_INT
,
272 TARGET_INT_BIT
/ TARGET_CHAR_BIT
,
273 0, "int", objfile
); /* FIXME -fnf */
275 case FT_UNSIGNED_INTEGER
:
276 type
= init_type (TYPE_CODE_INT
,
277 TARGET_INT_BIT
/ TARGET_CHAR_BIT
,
278 TYPE_FLAG_UNSIGNED
, "unsigned int", objfile
);
281 type
= init_type (TYPE_CODE_INT
,
282 TARGET_LONG_BIT
/ TARGET_CHAR_BIT
,
286 type
= init_type (TYPE_CODE_INT
,
287 TARGET_LONG_BIT
/ TARGET_CHAR_BIT
,
288 0, "long", objfile
); /* FIXME -fnf */
290 case FT_UNSIGNED_LONG
:
291 type
= init_type (TYPE_CODE_INT
,
292 TARGET_LONG_BIT
/ TARGET_CHAR_BIT
,
293 TYPE_FLAG_UNSIGNED
, "unsigned long", objfile
);
296 type
= init_type (TYPE_CODE_INT
,
297 TARGET_LONG_LONG_BIT
/ TARGET_CHAR_BIT
,
298 0, "long long", objfile
);
300 case FT_SIGNED_LONG_LONG
:
301 type
= init_type (TYPE_CODE_INT
,
302 TARGET_LONG_LONG_BIT
/ TARGET_CHAR_BIT
,
303 0, "signed long long", objfile
);
305 case FT_UNSIGNED_LONG_LONG
:
306 type
= init_type (TYPE_CODE_INT
,
307 TARGET_LONG_LONG_BIT
/ TARGET_CHAR_BIT
,
308 TYPE_FLAG_UNSIGNED
, "unsigned long long", objfile
);
311 type
= init_type (TYPE_CODE_FLT
,
312 TARGET_FLOAT_BIT
/ TARGET_CHAR_BIT
,
313 0, "float", objfile
);
315 case FT_DBL_PREC_FLOAT
:
316 type
= init_type (TYPE_CODE_FLT
,
317 TARGET_DOUBLE_BIT
/ TARGET_CHAR_BIT
,
318 0, "double", objfile
);
320 case FT_EXT_PREC_FLOAT
:
321 type
= init_type (TYPE_CODE_FLT
,
322 TARGET_LONG_DOUBLE_BIT
/ TARGET_CHAR_BIT
,
323 0, "long double", objfile
);
326 type
= init_type (TYPE_CODE_FLT
,
327 2 * TARGET_FLOAT_BIT
/ TARGET_CHAR_BIT
,
328 0, "complex float", objfile
);
329 TYPE_TARGET_TYPE (type
)
330 = init_type (TYPE_CODE_FLT
, TARGET_FLOAT_BIT
/ TARGET_CHAR_BIT
,
331 0, "float", objfile
);
333 case FT_DBL_PREC_COMPLEX
:
334 type
= init_type (TYPE_CODE_FLT
,
335 2 * TARGET_DOUBLE_BIT
/ TARGET_CHAR_BIT
,
336 0, "complex double", objfile
);
337 TYPE_TARGET_TYPE (type
)
338 = init_type (TYPE_CODE_FLT
, TARGET_DOUBLE_BIT
/ TARGET_CHAR_BIT
,
339 0, "double", objfile
);
341 case FT_EXT_PREC_COMPLEX
:
342 type
= init_type (TYPE_CODE_FLT
,
343 2 * TARGET_LONG_DOUBLE_BIT
/ TARGET_CHAR_BIT
,
344 0, "complex long double", objfile
);
345 TYPE_TARGET_TYPE (type
)
346 = init_type (TYPE_CODE_FLT
, TARGET_LONG_DOUBLE_BIT
/ TARGET_CHAR_BIT
,
347 0, "long double", objfile
);
349 case FT_TEMPLATE_ARG
:
350 type
= init_type (TYPE_CODE_TEMPLATE_ARG
,
352 0, "<template arg>", objfile
);
358 /* Preprocessing and parsing C and C++ expressions. */
361 /* When we find that lexptr (the global var defined in parse.c) is
362 pointing at a macro invocation, we expand the invocation, and call
363 scan_macro_expansion to save the old lexptr here and point lexptr
364 into the expanded text. When we reach the end of that, we call
365 end_macro_expansion to pop back to the value we saved here. The
366 macro expansion code promises to return only fully-expanded text,
367 so we don't need to "push" more than one level.
369 This is disgusting, of course. It would be cleaner to do all macro
370 expansion beforehand, and then hand that to lexptr. But we don't
371 really know where the expression ends. Remember, in a command like
373 (gdb) break *ADDRESS if CONDITION
375 we evaluate ADDRESS in the scope of the current frame, but we
376 evaluate CONDITION in the scope of the breakpoint's location. So
377 it's simply wrong to try to macro-expand the whole thing at once. */
378 static char *macro_original_text
;
379 static char *macro_expanded_text
;
383 scan_macro_expansion (char *expansion
)
385 /* We'd better not be trying to push the stack twice. */
386 gdb_assert (! macro_original_text
);
387 gdb_assert (! macro_expanded_text
);
389 /* Save the old lexptr value, so we can return to it when we're done
390 parsing the expanded text. */
391 macro_original_text
= lexptr
;
394 /* Save the expanded text, so we can free it when we're finished. */
395 macro_expanded_text
= expansion
;
400 scanning_macro_expansion (void)
402 return macro_original_text
!= 0;
407 finished_macro_expansion (void)
409 /* There'd better be something to pop back to, and we better have
410 saved a pointer to the start of the expanded text. */
411 gdb_assert (macro_original_text
);
412 gdb_assert (macro_expanded_text
);
414 /* Pop back to the original text. */
415 lexptr
= macro_original_text
;
416 macro_original_text
= 0;
418 /* Free the expanded text. */
419 xfree (macro_expanded_text
);
420 macro_expanded_text
= 0;
425 scan_macro_cleanup (void *dummy
)
427 if (macro_original_text
)
428 finished_macro_expansion ();
432 /* We set these global variables before calling c_parse, to tell it
433 how it to find macro definitions for the expression at hand. */
434 macro_lookup_ftype
*expression_macro_lookup_func
;
435 void *expression_macro_lookup_baton
;
438 static struct macro_definition
*
439 null_macro_lookup (const char *name
, void *baton
)
446 c_preprocess_and_parse (void)
448 /* Set up a lookup function for the macro expander. */
449 struct macro_scope
*scope
= 0;
450 struct cleanup
*back_to
= make_cleanup (free_current_contents
, &scope
);
452 if (expression_context_block
)
453 scope
= sal_macro_scope (find_pc_line (expression_context_pc
, 0));
455 scope
= default_macro_scope ();
459 expression_macro_lookup_func
= standard_macro_lookup
;
460 expression_macro_lookup_baton
= (void *) scope
;
464 expression_macro_lookup_func
= null_macro_lookup
;
465 expression_macro_lookup_baton
= 0;
468 gdb_assert (! macro_original_text
);
469 make_cleanup (scan_macro_cleanup
, 0);
472 int result
= c_parse ();
473 do_cleanups (back_to
);
480 /* Table mapping opcodes into strings for printing operators
481 and precedences of the operators. */
483 const struct op_print c_op_print_tab
[] =
485 {",", BINOP_COMMA
, PREC_COMMA
, 0},
486 {"=", BINOP_ASSIGN
, PREC_ASSIGN
, 1},
487 {"||", BINOP_LOGICAL_OR
, PREC_LOGICAL_OR
, 0},
488 {"&&", BINOP_LOGICAL_AND
, PREC_LOGICAL_AND
, 0},
489 {"|", BINOP_BITWISE_IOR
, PREC_BITWISE_IOR
, 0},
490 {"^", BINOP_BITWISE_XOR
, PREC_BITWISE_XOR
, 0},
491 {"&", BINOP_BITWISE_AND
, PREC_BITWISE_AND
, 0},
492 {"==", BINOP_EQUAL
, PREC_EQUAL
, 0},
493 {"!=", BINOP_NOTEQUAL
, PREC_EQUAL
, 0},
494 {"<=", BINOP_LEQ
, PREC_ORDER
, 0},
495 {">=", BINOP_GEQ
, PREC_ORDER
, 0},
496 {">", BINOP_GTR
, PREC_ORDER
, 0},
497 {"<", BINOP_LESS
, PREC_ORDER
, 0},
498 {">>", BINOP_RSH
, PREC_SHIFT
, 0},
499 {"<<", BINOP_LSH
, PREC_SHIFT
, 0},
500 {"+", BINOP_ADD
, PREC_ADD
, 0},
501 {"-", BINOP_SUB
, PREC_ADD
, 0},
502 {"*", BINOP_MUL
, PREC_MUL
, 0},
503 {"/", BINOP_DIV
, PREC_MUL
, 0},
504 {"%", BINOP_REM
, PREC_MUL
, 0},
505 {"@", BINOP_REPEAT
, PREC_REPEAT
, 0},
506 {"-", UNOP_NEG
, PREC_PREFIX
, 0},
507 {"!", UNOP_LOGICAL_NOT
, PREC_PREFIX
, 0},
508 {"~", UNOP_COMPLEMENT
, PREC_PREFIX
, 0},
509 {"*", UNOP_IND
, PREC_PREFIX
, 0},
510 {"&", UNOP_ADDR
, PREC_PREFIX
, 0},
511 {"sizeof ", UNOP_SIZEOF
, PREC_PREFIX
, 0},
512 {"++", UNOP_PREINCREMENT
, PREC_PREFIX
, 0},
513 {"--", UNOP_PREDECREMENT
, PREC_PREFIX
, 0},
517 enum c_primitive_types
{
518 c_primitive_type_int
,
519 c_primitive_type_long
,
520 c_primitive_type_short
,
521 c_primitive_type_char
,
522 c_primitive_type_float
,
523 c_primitive_type_double
,
524 c_primitive_type_void
,
525 c_primitive_type_long_long
,
526 c_primitive_type_signed_char
,
527 c_primitive_type_unsigned_char
,
528 c_primitive_type_unsigned_short
,
529 c_primitive_type_unsigned_int
,
530 c_primitive_type_unsigned_long
,
531 c_primitive_type_unsigned_long_long
,
532 c_primitive_type_long_double
,
533 c_primitive_type_complex
,
534 c_primitive_type_double_complex
,
539 c_language_arch_info (struct gdbarch
*gdbarch
,
540 struct language_arch_info
*lai
)
542 const struct builtin_type
*builtin
= builtin_type (gdbarch
);
543 lai
->string_char_type
= builtin
->builtin_char
;
544 lai
->primitive_type_vector
545 = GDBARCH_OBSTACK_CALLOC (gdbarch
, nr_c_primitive_types
+ 1,
547 lai
->primitive_type_vector
[c_primitive_type_int
] = builtin
->builtin_int
;
548 lai
->primitive_type_vector
[c_primitive_type_long
] = builtin
->builtin_long
;
549 lai
->primitive_type_vector
[c_primitive_type_short
] = builtin
->builtin_short
;
550 lai
->primitive_type_vector
[c_primitive_type_char
] = builtin
->builtin_char
;
551 lai
->primitive_type_vector
[c_primitive_type_float
] = builtin
->builtin_float
;
552 lai
->primitive_type_vector
[c_primitive_type_double
] = builtin
->builtin_double
;
553 lai
->primitive_type_vector
[c_primitive_type_void
] = builtin
->builtin_void
;
554 lai
->primitive_type_vector
[c_primitive_type_long_long
] = builtin
->builtin_long_long
;
555 lai
->primitive_type_vector
[c_primitive_type_signed_char
] = builtin
->builtin_signed_char
;
556 lai
->primitive_type_vector
[c_primitive_type_unsigned_char
] = builtin
->builtin_unsigned_char
;
557 lai
->primitive_type_vector
[c_primitive_type_unsigned_short
] = builtin
->builtin_unsigned_short
;
558 lai
->primitive_type_vector
[c_primitive_type_unsigned_int
] = builtin
->builtin_unsigned_int
;
559 lai
->primitive_type_vector
[c_primitive_type_unsigned_long
] = builtin
->builtin_unsigned_long
;
560 lai
->primitive_type_vector
[c_primitive_type_unsigned_long_long
] = builtin
->builtin_unsigned_long_long
;
561 lai
->primitive_type_vector
[c_primitive_type_long_double
] = builtin
->builtin_long_double
;
562 lai
->primitive_type_vector
[c_primitive_type_complex
] = builtin
->builtin_complex
;
563 lai
->primitive_type_vector
[c_primitive_type_double_complex
] = builtin
->builtin_double_complex
;
566 const struct language_defn c_language_defn
=
568 "c", /* Language name */
575 &exp_descriptor_standard
,
576 c_preprocess_and_parse
,
579 c_printchar
, /* Print a character constant */
580 c_printstr
, /* Function to print string constant */
581 c_emit_char
, /* Print a single char */
582 c_create_fundamental_type
, /* Create fundamental type in this language */
583 c_print_type
, /* Print a type using appropriate syntax */
584 c_val_print
, /* Print a value using appropriate syntax */
585 c_value_print
, /* Print a top-level value */
586 NULL
, /* Language specific skip_trampoline */
587 NULL
, /* value_of_this */
588 basic_lookup_symbol_nonlocal
, /* lookup_symbol_nonlocal */
589 basic_lookup_transparent_type
,/* lookup_transparent_type */
590 NULL
, /* Language specific symbol demangler */
591 NULL
, /* Language specific class_name_from_physname */
592 c_op_print_tab
, /* expression operators for printing */
593 1, /* c-style arrays */
594 0, /* String lower bound */
596 default_word_break_characters
,
597 c_language_arch_info
,
601 struct type
**const (cplus_builtin_types
[]) =
608 &builtin_type_double
,
610 &builtin_type_long_long
,
611 &builtin_type_signed_char
,
612 &builtin_type_unsigned_char
,
613 &builtin_type_unsigned_short
,
614 &builtin_type_unsigned_int
,
615 &builtin_type_unsigned_long
,
616 &builtin_type_unsigned_long_long
,
617 &builtin_type_long_double
,
618 &builtin_type_complex
,
619 &builtin_type_double_complex
,
624 const struct language_defn cplus_language_defn
=
626 "c++", /* Language name */
633 &exp_descriptor_standard
,
634 c_preprocess_and_parse
,
637 c_printchar
, /* Print a character constant */
638 c_printstr
, /* Function to print string constant */
639 c_emit_char
, /* Print a single char */
640 c_create_fundamental_type
, /* Create fundamental type in this language */
641 c_print_type
, /* Print a type using appropriate syntax */
642 c_val_print
, /* Print a value using appropriate syntax */
643 c_value_print
, /* Print a top-level value */
644 NULL
, /* Language specific skip_trampoline */
645 value_of_this
, /* value_of_this */
646 cp_lookup_symbol_nonlocal
, /* lookup_symbol_nonlocal */
647 cp_lookup_transparent_type
, /* lookup_transparent_type */
648 cplus_demangle
, /* Language specific symbol demangler */
649 cp_class_name_from_physname
, /* Language specific class_name_from_physname */
650 c_op_print_tab
, /* expression operators for printing */
651 1, /* c-style arrays */
652 0, /* String lower bound */
653 &builtin_type_char
, /* Type of string elements */
654 default_word_break_characters
,
655 NULL
, /* FIXME: la_language_arch_info. */
659 const struct language_defn asm_language_defn
=
661 "asm", /* Language name */
668 &exp_descriptor_standard
,
669 c_preprocess_and_parse
,
672 c_printchar
, /* Print a character constant */
673 c_printstr
, /* Function to print string constant */
674 c_emit_char
, /* Print a single char */
675 c_create_fundamental_type
, /* Create fundamental type in this language */
676 c_print_type
, /* Print a type using appropriate syntax */
677 c_val_print
, /* Print a value using appropriate syntax */
678 c_value_print
, /* Print a top-level value */
679 NULL
, /* Language specific skip_trampoline */
680 NULL
, /* value_of_this */
681 basic_lookup_symbol_nonlocal
, /* lookup_symbol_nonlocal */
682 basic_lookup_transparent_type
,/* lookup_transparent_type */
683 NULL
, /* Language specific symbol demangler */
684 NULL
, /* Language specific class_name_from_physname */
685 c_op_print_tab
, /* expression operators for printing */
686 1, /* c-style arrays */
687 0, /* String lower bound */
689 default_word_break_characters
,
690 c_language_arch_info
, /* FIXME: la_language_arch_info. */
694 /* The following language_defn does not represent a real language.
695 It just provides a minimal support a-la-C that should allow users
696 to do some simple operations when debugging applications that use
697 a language currently not supported by GDB. */
699 const struct language_defn minimal_language_defn
=
701 "minimal", /* Language name */
708 &exp_descriptor_standard
,
709 c_preprocess_and_parse
,
712 c_printchar
, /* Print a character constant */
713 c_printstr
, /* Function to print string constant */
714 c_emit_char
, /* Print a single char */
715 c_create_fundamental_type
, /* Create fundamental type in this language */
716 c_print_type
, /* Print a type using appropriate syntax */
717 c_val_print
, /* Print a value using appropriate syntax */
718 c_value_print
, /* Print a top-level value */
719 NULL
, /* Language specific skip_trampoline */
720 NULL
, /* value_of_this */
721 basic_lookup_symbol_nonlocal
, /* lookup_symbol_nonlocal */
722 basic_lookup_transparent_type
,/* lookup_transparent_type */
723 NULL
, /* Language specific symbol demangler */
724 NULL
, /* Language specific class_name_from_physname */
725 c_op_print_tab
, /* expression operators for printing */
726 1, /* c-style arrays */
727 0, /* String lower bound */
729 default_word_break_characters
,
730 c_language_arch_info
,
735 _initialize_c_language (void)
737 add_language (&c_language_defn
);
738 add_language (&cplus_language_defn
);
739 add_language (&asm_language_defn
);
740 add_language (&minimal_language_defn
);