I've run into a situation where reaper.RCD successfully creates a folder but returns 0, which trips up my script's error handling. Reaper 5.78, Win 8.1 x64.
Code:
local ret = reaper.RecursiveCreateDirectory("C:\\test", 0)
--> 1 and c:\test now exists, as per the API.
local ret = reaper.RecursiveCreateDirectory("C:\\Users\\REDACTED\\AppData\\Roaming\\
REAPER\\Scripts\\Lokasenna\\Lokasenna_GUI\\compiled", 0)
--> 0, but ...\compiled now exists anyway
Cheers.