[vala] Do not warn for non-default parameter if it's ellipsis
- From: Luca Bruno <lucabru src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [vala] Do not warn for non-default parameter if it's ellipsis
- Date: Sat, 24 Aug 2013 11:46:37 +0000 (UTC)
commit e331049d0f66a04a1d3dc2c64eedf1a4f574c6ec
Author: Luca Bruno <lucabru src gnome org>
Date: Sat Aug 24 13:45:56 2013 +0200
Do not warn for non-default parameter if it's ellipsis
vala/valamethod.vala | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/vala/valamethod.vala b/vala/valamethod.vala
index f1b7577..d1129d8 100644
--- a/vala/valamethod.vala
+++ b/vala/valamethod.vala
@@ -661,7 +661,7 @@ public class Vala.Method : Subroutine {
error = true;
Report.error (param.source_reference, "Reference parameters are not supported
for async methods");
}
- if (optional_param && param.initializer == null) {
+ if (optional_param && param.initializer == null && !param.ellipsis) {
Report.warning (param.source_reference, "parameter without default follows
parameter with default");
} else if (param.initializer != null) {
optional_param = true;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]