sources/format.h

changeset 10
3874575d924d
parent 5
146825d63b9a
child 11
cffa2777d917
equal deleted inserted replaced
9:e7a09ceb4505 10:3874575d924d
26 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING 26 LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
27 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS 27 NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
28 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 28 SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 */ 29 */
30 30
31 #pragma once
31 #include "mystring.h" 32 #include "mystring.h"
32 #include "basics.h" 33 #include "basics.h"
33 #include "geometry.h" 34 #include "geometry.h"
34 35
35 #define FORMAT_OVERLOAD(T) \ 36 #define FORMAT_OVERLOAD(T) \
114 // Expands the given arguments into a vector of strings. 115 // Expands the given arguments into a vector of strings.
115 // 116 //
116 template<typename T, typename... RestTypes> FUNCTION 117 template<typename T, typename... RestTypes> FUNCTION
117 expand_format_arguments (Vector<String>& data, const T& arg, const RestTypes& ... rest) -> void 118 expand_format_arguments (Vector<String>& data, const T& arg, const RestTypes& ... rest) -> void
118 { 119 {
119 data.append (make_format_argument (arg).text()); 120 data.append (make_format_argument (arg));
120 expand_format_arguments (data, rest...); 121 expand_format_arguments (data, rest...);
121 } 122 }
122 123
123 static void expand_format_arguments (Vector<String>&) __attribute__((unused)); 124 static void expand_format_arguments (Vector<String>&) __attribute__((unused));
124 static void expand_format_arguments (Vector<String>&) {} 125 static void expand_format_arguments (Vector<String>&) {}

mercurial