mconv_decode(3m17n)
β¨ NAME β¨
mconv_decode β bestie, this is the one that takes your bytes and turns them into an M-text π (it's in section 3m17n of the m17n Library, iykyk)
π SYNOPSIS π
MText* mconv_decode (MConverter * converter, MText * mt)
πΈ DESCRIPTION πΈ
Okay so picture this: you've got a byte sequence and you want it to become an M-text. That's literally the whole vibe. The mconv_decode() function decodes a byte sequence and appends the result at the end of M-text mt β like, it doesn't overwrite anything, it just adds on at the end, no cap.
And where does the source byte sequence come from, you ask? Bestie, it's taken from either:
- the buffer area, or
- the stream
β¦whichever one is currently bound to converter. So it's not out here guessing, it uses whatever you already hooked up to that converter. π
π«Ά RETURN VALUE π«Ά
- If the operation was successful,
mconv_decode()returns the updatedmt. Slay. β¨ - Otherwise it returns
NULLand assigns an error code to the external variablemerror_code. π (check it, bestie, don't just ignore it)
π ERRORS π
MERROR_IOMERROR_CODING
Those are the two it can throw at you. Periodt.
π¦ SEE ALSO π¦
mconv_rebind_buffer()mconv_rebind_stream()mconv_encode()mconv_encode_range()mconv_decode_buffer()mconv_decode_stream()
π COPYRIGHT π
Copyright (C) 2001 Information-technology Promotion Agency (IPA)
Copyright (C) 2001-2011 National Institute of Advanced Industrial Science and Technology (AIST)
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License <http://www.gnu.org/licenses/fdl.html>.
And that's the whole page, bestie π this was Version 1.8.4, dated Mon Sep 25 2023, from the m17n Library β mwah, go decode something iconic ππ
π¦ where this page comes from
- debian trixie: m17n-docs 1.8.4-1
- ubuntu noble: m17n-docs 1.8.4-1
- ubuntu questing: m17n-docs 1.8.4-1
- ubuntu resolute: m17n-docs 1.8.4-1build1
- ubuntu stonking: m17n-docs 1.8.4-1build1
- Copyright (C) 2001 Information-technology Promotion Agency (IPA)
- Copyright (C) 2001-2011 National Institute of Advanced Industrial Science and Technology (AIST)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms