tags:

views:

504

answers:

2

According to the manual, string concatenation isn't implemented in gdb. I need it however, so is there a way to achieve this, perhaps using array functions?

A: 

For Objective-C: [@"asd" stringByAppendingString:@"zxc"] Ex: po [@"ID: " stringByAppendingString:(NSString*)[aTaskDict valueForKey:@"ID"]]

A: 

I don't have a copy of gdb around to try this on, but perhaps this line from later in the Ada section of the document will help you?

Rather than use catenation and symbolic character names to introduce special characters into strings, one may instead use a special bracket notation, which is also used to print strings. A sequence of characters of the form ["XX"]' within a string or character literal denotes the (single) character whose numeric encoding is XX in hexadecimal. The sequence of characters ["""]' also denotes a single quotation mark in strings. For example, "One line.["0a"]Next line.["0a"]"

contains an ASCII newline character (Ada.Characters.Latin_1.LF) after each period.

T.E.D.