The following code reproduces the error case.
select to_timestamp(CAST(split_part('1386577650.123', '.', 1) as INT8));
FAILURE: Integrated in Tajo-trunk-postcommit #630 (See https://builds.apache.org/job/Tajo-trunk-postcommit/630/)
TAJO-442: Cast operator with nested functions causes NPE. (hyunsik) (hyunsik: https://git-wip-us.apache.org/repos/asf?p=incubator-tajo.git&a=commit&h=450fbcb93c02c74fd8889751bdec5ce155e3e294)
I've committed it to master branch. Thank you guys for the review.
Looks great for me. I've verified 'mvn clean install'.
This looks pretty straightforward.
I've uploaded the bug fix.