Thread (1 message) 1 message, 1 author, 2011-09-08

Re: [PATCH v2 3/3] dtc: Support character literals in bytestrings

From: Grant Likely <hidden>
Date: 2011-09-08 07:07:16

On Thu, Sep 08, 2011 at 01:51:49PM +1000, David Gibson wrote:
On Wed, Sep 07, 2011 at 04:15:40PM -0700, Anton Staaf wrote:
quoted
With this patch the following property assignment:

    property = ['a' 2b '\r'];

is equivalent to:

    property = [61 2b 0d];
So, I still have some reservations about this syntax.

It occurred to me: do you actually need to intermix character and
hexbyte values that much?  Could I suggest an alternate sytax as:

	property = 'a', [2b], 'r';

The new character literals sufficiently distinct not to cause problems
here, and it maintains the , == bytestring append behaviour we already
have.

Thoughts?
Does it matter much?  I'm happy with either.  Is there a downside to
the first syntax?

g.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help