0

Mono is throwing the warning:

warning CS0414: The private field 'Convergence.Core.Services.PermissionService.userService' is assigned but its value is never used

Which is strange, since it is most certainly used:

For instance:

var systemRoles = (
    from e 
    in systemRoleRepository.Entities 
    where e.User.Username.Equals(userService.CurrentUser.Username)
    select e
).ToList();

(The where clause makes use of userService).

The object is the same object that the compiler is comlaining about, and is declared as:

private readonly IUserService userService;

To determine that it is in fact being used, if I comment out the declaration, the Mono compiler throws and error on that LINQ query saying userService isn't declared.

Am I missing something really really obvious, or is this a bug in the mono compiler (dmcs on 2.8.1 on RHEL 5.5 by the way).

Michael Shimmins
  • 19,961
  • 7
  • 57
  • 90

1 Answers1

1

This is almost certainly a bug. Please file it at Novell's bug tracker.

cdhowie
  • 158,093
  • 24
  • 286
  • 300
  • Thanks - I searched for it in bugzilla prior to posting, but evidently not very well. Found it as soon as I went to raise the case: https://bugzilla.novell.com/show_bug.cgi?id=625583 – Michael Shimmins Nov 21 '10 at 02:01