Improve programming style.

This commit is contained in:
Zoltan Somogyi
2025-08-04 12:42:36 +02:00
parent ffcd2bb62c
commit 71acd2444f

View File

@@ -21,7 +21,7 @@ tmp_declare_entry="/tmp/make_port_code_decl_$$"
tmp_define_entry="/tmp/make_port_code_defn_$$"
tmp_init_entry="/tmp/make_port_code_init_$$"
tmp_hlc="/tmp/make_port_code_hlc_$$"
trap "/bin/rm $tmp_code $tmp_prolog $tmp_declare_entry $tmp_define_entry $tmp_init_entry $tmp_hlc" 0 1 2 3 15
trap "/bin/rm ${tmp_code} ${tmp_prolog} ${tmp_declare_entry} ${tmp_define_entry} ${tmp_init_entry} ${tmp_hlc}" 0 1 2 3 15
> ${tmp_code}
> ${tmp_declare_entry}
> ${tmp_define_entry}
@@ -30,7 +30,7 @@ trap "/bin/rm $tmp_code $tmp_prolog $tmp_declare_entry $tmp_define_entry $tmp_in
cat > ${tmp_prolog} << END
// Copyright (C) 2002 The University of Melbourne.
// Copyright (C) 2016, 2018 The Mercury team.
// Copyright (C) 2016, 2018, 2025 The Mercury team.
// This file is distributed under the terms specified in COPYING.LIB.
// The contents of this file were generated by the make_port_code script
@@ -258,8 +258,10 @@ cat >> ${source} << END
END
cat ${tmp_define_entry} >> ${source}
echo >> ${source}
echo "MR_BEGIN_MODULE(${module})" >> ${source}
cat ${tmp_init_entry} >> ${source}
echo >> ${source}
echo "MR_BEGIN_CODE" >> ${source}
cat ${tmp_code} >> ${source}
cat >> ${source} << END