bugGNU Octave - Bugs: bug #52574, Byte-order-mark handling


bug #52574: Byte-order-mark handling

Submitted by:  Ben Cox <mitlik>
Submitted on:  Fri 01 Dec 2017 08:30:03 PM UTC  
Category:  Interpreter Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  Closed
Release:  dev Operating System:  Any

Add a New Comment(Rich Markup)

You are not logged in

Please log in, so followups can be emailed to you.


Fri 03 Aug 2018 07:07:29 PM UTC, comment #2:

Closing as fixed.

Markus Mützel <mmuetzel>
Project Member
Sat 14 Jul 2018 12:19:20 PM UTC, comment #1:

The issue should be fixed on the development branch with this changeset:

Marking as Ready for Test.

Markus Mützel <mmuetzel>
Project Member
Fri 01 Dec 2017 08:30:03 PM UTC, original submission:

Octave interpreter gives syntax error while running script files that begin with a byte-order-mark (BOM).

Operating System: Windows 7 Professional 32-bit [Version 6.1.7601]
Octave Information: 4.2.1 configured for "i686-w64-mingw32" (i.e. installed from the windows installer available through the Octave website)

  • called using "C:\Octave\Octave-4.2.1\octave.vbs --force-gui"

To reproduce modify any working script to include a BOM. In vim that would look like:

Alternately, in Notepad it is possible to Save As with UTF-8 encoding, which defaults to putting a byte-order-mark in place.

After the BOM is added, the octave interpreter will throw a syntax error on the BOM.

Example contents of "bomtest.m":

Example run and output (using the Octave GUI, octave-cli doesn't show characters in the syntax error):

Ben Cox <mitlik>


(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:

No files currently attached


Depends on the following items: None found

Items that depend on this one: None found


Carbon-Copy List
  • -email is unavailable- added by mmuetzel (Posted a comment)
  • -email is unavailable- added by mitlik (Submitted the item)

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.




    Follow 5 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-08-03 mmuetzel StatusReady For Test => Fixed
        Open/ClosedOpen => Closed
    2018-07-14 mmuetzel Release4.2.1 => dev
        Operating SystemMicrosoft Windows => Any
    2018-07-14 mmuetzel StatusNone => Ready For Test

    Back to the top

    Powered by Savane 3.4