get { return _bol; }
}
+ static GLib.Regex fix_indent_regex;
+
private string temp_filename;
private bool file_exists;
bool first = true;
// discard tabs at beginning of line
- unowned Regex fix_indent_regex = /^\t+/;
+ if (fix_indent_regex == null)
+ fix_indent_regex = new GLib.Regex ("^\t+");;
foreach (unowned string line in text.split ("\n")) {
if (!first) {
* }}}
*/
public bool set_colors (string str) {
- unowned Regex val_regex = /^\\s*[0-9]+(;[0-9]*)*\\s*$/;
+ Regex val_regex;
+ try {
+ val_regex = new Regex ("^\\s*[0-9]+(;[0-9]*)*\\s*$");
+ } catch (RegexError e) {
+ assert_not_reached ();
+ }
string error_color = null;
string warning_color = null;
public bool enable_warnings { get; set; default = true; }
+ static GLib.Regex val_regex;
+
/**
* Set all colors by string
*
* }}}
*/
public bool set_colors (string str, Report.Colored colored_output = Report.Colored.AUTO) {
- unowned Regex val_regex = /^\\s*[0-9]+(;[0-9]*)*\\s*$/;
+ try {
+ if (val_regex == null)
+ val_regex = new Regex ("^\\s*[0-9]+(;[0-9]*)*\\s*$");
+ } catch (RegexError e) {
+ assert_not_reached ();
+ }
string error_color = null;
string warning_color = null;