X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=gdb%2Frust-lang.h;h=d8acbccf9ef235af5ea50f88bb805a774594e4c3;hb=9aa5520697ee3b65bfbb705c21c2dfb2c0dee12e;hp=8f2b6826c152eabfcb6950bc38220b687f9d10f7;hpb=65c40c956fcd9443a5390d6cc36f84bd1bf77df4;p=external%2Fbinutils.git diff --git a/gdb/rust-lang.h b/gdb/rust-lang.h index 8f2b682..d8acbcc 100644 --- a/gdb/rust-lang.h +++ b/gdb/rust-lang.h @@ -1,6 +1,6 @@ /* Rust language support definitions for GDB, the GNU debugger. - Copyright (C) 2016-2017 Free Software Foundation, Inc. + Copyright (C) 2016-2019 Free Software Foundation, Inc. This file is part of GDB. @@ -26,9 +26,6 @@ struct type; /* The la_parser implementation for Rust. */ extern int rust_parse (struct parser_state *); -/* The la_error implementation for Rust. */ -extern void rustyyerror (char *); - /* Return true if TYPE is a tuple type; otherwise false. */ extern bool rust_tuple_type_p (struct type *type); @@ -39,11 +36,16 @@ extern bool rust_tuple_struct_type_p (struct type *type); stringif no crate name can be found. */ extern std::string rust_crate_for_block (const struct block *block); +/* Returns the last segment of a Rust path like foo::bar::baz. Will + not handle cases where the last segment contains generics. */ + +extern const char *rust_last_path_segment (const char *path); + /* Create a new slice type. NAME is the name of the type. ELT_TYPE is the type of the elements of the slice. USIZE_TYPE is the Rust "usize" type to use. The new type is allocated whereever ELT_TYPE is allocated. */ -struct type *rust_slice_type (const char *name, struct type *elt_type, - struct type *usize_type); +extern struct type *rust_slice_type (const char *name, struct type *elt_type, + struct type *usize_type); #endif /* RUST_LANG_H */