[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
struct concatenation
From: |
c. |
Subject: |
struct concatenation |
Date: |
Thu, 7 Jul 2016 09:23:16 +0200 |
Hi,
Say you have two struct variables
>> s1
s1 =
scalar structure containing the fields:
a: 1x1 scalar
b: 1x1 scalar
>> s2
s2 =
scalar structure containing the fields:
c: 1x1 scalar
d: 1x1 scalar
and I want to create a new struct s that contains all fields of both.
what would be a clean way of doing this?
All I came up with for the moment was cycling over s1 and s2 and assigning
each field to s, is there a better way?
c.
- struct concatenation,
c. <=