1
0
mirror of https://github.com/fluencelabs/wasmer synced 2024-12-15 23:25:41 +00:00
wasmer/lib/emscripten-tests/emtests/test_sscanf_float.c

18 lines
609 B
C
Raw Normal View History

2018-12-27 07:46:41 +00:00
/*
* Copyright 2016 The Emscripten Authors. All rights reserved.
* Emscripten is available under two separate licenses, the MIT license and the
* University of Illinois/NCSA Open Source License. Both these licenses can be
* found in the LICENSE file.
*/
#include "stdio.h"
int main() {
float f1, f2, f3, f4, f5, f6, f7, f8, f9;
sscanf("0.512 0.250x5.129_-9.98 1.12*+54.32E3 +54.32E3^87.5E-3 87.5E-3$",
"%f %fx%f_%f %f*%f %f^%f %f$", &f1, &f2, &f3, &f4, &f5, &f6, &f7, &f8,
&f9);
printf("\n%f, %f, %f, %f, %f, %f, %f, %f, %f\n", f1, f2, f3, f4, f5, f6, f7,
f8, f9);
}