Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 25 Mar 2017 13:17:49 +0000 (UTC)
From:      Dimitry Andric <dim@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r315947 - head/contrib/libcxxrt
Message-ID:  <201703251317.v2PDHnAh096366@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: dim
Date: Sat Mar 25 13:17:48 2017
New Revision: 315947
URL: https://svnweb.freebsd.org/changeset/base/315947

Log:
  Import libcxxrt master 8a853717e61d5d55cbdf74d9d0a7545da5d5ff92.
  
  Interesting fixes which were not already merged:
  0c7c611 Merge C++ demangler bug fixes from ELF Tool Chain (#40)
  2b208d9 __cxa_demangle_gnu3: demangle 'z' as '...', not 'ellipsis' (#41)
  
  MFC after:	3 days

Modified:
  head/contrib/libcxxrt/libelftc_dem_gnu3.c
Directory Properties:
  head/contrib/libcxxrt/   (props changed)

Modified: head/contrib/libcxxrt/libelftc_dem_gnu3.c
==============================================================================
--- head/contrib/libcxxrt/libelftc_dem_gnu3.c	Sat Mar 25 13:15:43 2017	(r315946)
+++ head/contrib/libcxxrt/libelftc_dem_gnu3.c	Sat Mar 25 13:17:48 2017	(r315947)
@@ -846,7 +846,7 @@ cpp_demangle_push_type_qualifier(struct 
 			free(buf);
 			++e_idx;
 			break;
-		};
+		}
 		--idx;
 	}
 
@@ -1007,7 +1007,7 @@ cpp_demangle_read_expr_primary(struct cp
 			return (cpp_demangle_push_str(ddata, "true", 4));
 		default:
 			return (0);
-		};
+		}
 
 	case 'd':
 		++ddata->cur;
@@ -1057,7 +1057,7 @@ cpp_demangle_read_expr_primary(struct cp
 
 	default:
 		return (0);
-	};
+	}
 }
 
 static int
@@ -1332,14 +1332,14 @@ cpp_demangle_read_expression(struct cpp_
 		/* operator sizeof */
 		ddata->cur += 2;
 		return (cpp_demangle_read_expression_unary(ddata, "sizeof", 6));
-	};
+	}
 
 	switch (*ddata->cur) {
 	case 'L':
 		return (cpp_demangle_read_expr_primary(ddata));
 	case 'T':
 		return (cpp_demangle_read_tmpl_param(ddata));
-	};
+	}
 
 	return (0);
 }
@@ -1555,11 +1555,13 @@ cpp_demangle_read_encoding(struct cpp_de
 			if (!cpp_demangle_push_str(ddata,
 			    "non-transaction clone for ", 26))
 				return (0);
+			break;
 		case 't':
 		default:
 			if (!cpp_demangle_push_str(ddata,
 			    "transaction clone for ", 22))
 				return (0);
+			break;
 		}
 		++ddata->cur;
 		return (cpp_demangle_read_encoding(ddata));
@@ -1712,7 +1714,7 @@ cpp_demangle_read_encoding(struct cpp_de
 		if (*ddata->cur == '\0')
 			return (0);
 		break;
-	};
+	}
 
 	return (cpp_demangle_read_name(ddata));
 }
@@ -1784,7 +1786,7 @@ cpp_demangle_read_name(struct cpp_demang
 		return (cpp_demangle_read_nested_name(ddata));
 	case 'Z':
 		return (cpp_demangle_read_local_name(ddata));
-	};
+	}
 
 	if (!vector_str_init(&v))
 		return (0);
@@ -1885,7 +1887,7 @@ cpp_demangle_read_nested_name(struct cpp
 		case 'K':
 			ddata->mem_cst = true;
 			break;
-		};
+		}
 		++ddata->cur;
 	}
 
@@ -1913,7 +1915,7 @@ cpp_demangle_read_nested_name(struct cpp
 		default:
 			if (!cpp_demangle_read_uqname(ddata))
 				goto clean;
-		};
+		}
 
 		if ((subst_str = vector_str_substr(output, p_idx,
 		    output->size - 1, &subst_str_len)) == NULL)
@@ -2188,35 +2190,35 @@ cpp_demangle_read_subst(struct cpp_deman
 
 	case SIMPLE_HASH('S', 'd'):
 		/* std::basic_iostream<char, std::char_traits<char> > */
-		if (!cpp_demangle_push_str(ddata, "std::iostream", 19))
+		if (!cpp_demangle_push_str(ddata, "std::basic_iostream", 19))
 			return (0);
-		ddata->last_sname = "iostream";
+		ddata->last_sname = "basic_iostream";
 		ddata->cur += 2;
 		if (*ddata->cur == 'I')
 			return (cpp_demangle_read_subst_stdtmpl(ddata,
-			    "std::iostream", 19));
+			    "std::basic_iostream", 19));
 		return (1);
 
 	case SIMPLE_HASH('S', 'i'):
 		/* std::basic_istream<char, std::char_traits<char> > */
-		if (!cpp_demangle_push_str(ddata, "std::istream", 18))
+		if (!cpp_demangle_push_str(ddata, "std::basic_istream", 18))
 			return (0);
-		ddata->last_sname = "istream";
+		ddata->last_sname = "basic_istream";
 		ddata->cur += 2;
 		if (*ddata->cur == 'I')
 			return (cpp_demangle_read_subst_stdtmpl(ddata,
-			    "std::istream", 18));
+			    "std::basic_istream", 18));
 		return (1);
 
 	case SIMPLE_HASH('S', 'o'):
 		/* std::basic_ostream<char, std::char_traits<char> > */
-		if (!cpp_demangle_push_str(ddata, "std::ostream", 18))
+		if (!cpp_demangle_push_str(ddata, "std::basic_ostream", 18))
 			return (0);
-		ddata->last_sname = "istream";
+		ddata->last_sname = "basic_ostream";
 		ddata->cur += 2;
 		if (*ddata->cur == 'I')
 			return (cpp_demangle_read_subst_stdtmpl(ddata,
-			    "std::ostream", 18));
+			    "std::basic_ostream", 18));
 		return (1);
 
 	case SIMPLE_HASH('S', 's'):
@@ -2238,7 +2240,7 @@ cpp_demangle_read_subst(struct cpp_deman
 	case SIMPLE_HASH('S', 't'):
 		/* std:: */
 		return (cpp_demangle_read_subst_std(ddata));
-	};
+	}
 
 	if (*(++ddata->cur) == '\0')
 		return (0);
@@ -2386,7 +2388,7 @@ cpp_demangle_read_tmpl_arg(struct cpp_de
 		return (cpp_demangle_read_expr_primary(ddata));
 	case 'X':
 		return (cpp_demangle_read_expression(ddata));
-	};
+	}
 
 	return (cpp_demangle_read_type(ddata, 0));
 }
@@ -2863,11 +2865,11 @@ again:
 
 	case 'z':
 		/* ellipsis */
-		if (!cpp_demangle_push_str(ddata, "ellipsis", 8))
+		if (!cpp_demangle_push_str(ddata, "...", 3))
 			goto clean;
 		++ddata->cur;
 		goto rtn;
-	};
+	}
 
 	if (!cpp_demangle_read_name(ddata))
 		goto clean;
@@ -3331,7 +3333,7 @@ cpp_demangle_read_uqname(struct cpp_dema
 			return (0);
 		ddata->cur += 2;
 		return (1);
-	};
+	}
 
 	/* vendor extened operator */
 	if (*ddata->cur == 'v' && ELFTC_ISDIGIT(*(ddata->cur + 1))) {
@@ -3377,7 +3379,7 @@ cpp_demangle_read_uqname(struct cpp_dema
 			return (0);
 		ddata->cur +=2;
 		return (1);
-	};
+	}
 
 	/* source name */
 	if (ELFTC_ISDIGIT(*ddata->cur) != 0)
@@ -3740,7 +3742,7 @@ hex_to_dec(char c)
 		return (15);
 	default:
 		return (-1);
-	};
+	}
 }
 
 static void



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201703251317.v2PDHnAh096366>