ObjFW  Check-in [1bf25c9a98]

Overview
Comment:of_asprintf: Generalize some #ifdefs

All workarounds that were for Wii and PSP are caused by newlib, so it's
better to check for newlib instead.

Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 1bf25c9a98a19ec504f353ddaa17eacfd636ff070ecc73bb3f6c4ba68075b66c
User & Date: js on 2014-04-26 01:02:42
Other Links: manifest | tags
Context
2014-04-26
01:04
Improve description for I/O related exceptions check-in: e05bd4856e user: js tags: trunk
01:02
of_asprintf: Generalize some #ifdefs check-in: 1bf25c9a98 user: js tags: trunk
00:57
configure: Improve warning about an old compiler check-in: 216ac1450c user: js tags: trunk
Changes

Modified src/of_asprintf.m from [9e4f7d3917] to [b1b058c113].

197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
		}

		break;
	case 'j':
#if defined(_WIN32)
		if (!appendSubformat(ctx, "I64", 3))
			return false;
#elif defined(__wii__) || defined(_PSP)
		if (!appendSubformat(ctx, "ll", 2))
			return false;
#else
		if (!appendSubformat(ctx, ctx->format + ctx->i, 1))
			return false;
#endif

		ctx->lengthModifier = LENGTH_MODIFIER_J;

		break;
	case 'z':
#if defined(_WIN32)
		if (!appendSubformat(ctx, "I", 1))
			return false;
#elif defined(__wii__) || defined(_PSP)
		if (!appendSubformat(ctx, "l", 1))
			return false;
#else
		if (!appendSubformat(ctx, ctx->format + ctx->i, 1))
			return false;
#endif

		ctx->lengthModifier = LENGTH_MODIFIER_Z;

		break;
	case 't':
#if defined(_WIN32)
		if (!appendSubformat(ctx, "I", 1))
			return false;
#elif defined(__wii__) || defined(_PSP)
		if (!appendSubformat(ctx, "l", 1))
			return false;
#else
		if (!appendSubformat(ctx, ctx->format + ctx->i, 1))
			return false;
#endif








|














|














|







197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
		}

		break;
	case 'j':
#if defined(_WIN32)
		if (!appendSubformat(ctx, "I64", 3))
			return false;
#elif defined(_NEWLIB_VERSION)
		if (!appendSubformat(ctx, "ll", 2))
			return false;
#else
		if (!appendSubformat(ctx, ctx->format + ctx->i, 1))
			return false;
#endif

		ctx->lengthModifier = LENGTH_MODIFIER_J;

		break;
	case 'z':
#if defined(_WIN32)
		if (!appendSubformat(ctx, "I", 1))
			return false;
#elif defined(_NEWLIB_VERSION)
		if (!appendSubformat(ctx, "l", 1))
			return false;
#else
		if (!appendSubformat(ctx, ctx->format + ctx->i, 1))
			return false;
#endif

		ctx->lengthModifier = LENGTH_MODIFIER_Z;

		break;
	case 't':
#if defined(_WIN32)
		if (!appendSubformat(ctx, "I", 1))
			return false;
#elif defined(_NEWLIB_VERSION)
		if (!appendSubformat(ctx, "l", 1))
			return false;
#else
		if (!appendSubformat(ctx, ctx->format + ctx->i, 1))
			return false;
#endif